home *** CD-ROM | disk | FTP | other *** search
/ SuperHack / SuperHack CD.bin / CODING / DELPHI / D_TAPI.ZIP / TAPI.PAS < prev    next >
Encoding:
Pascal/Delphi Source File  |  1996-07-01  |  89.6 KB  |  2,908 lines

  1. {
  2.  The  Telephony  API  is jointly copyrighted by Intel and Microsoft.  You are
  3.  granted  a royalty free worldwide, unlimited license to make copies, and use
  4.  the   API/SPI  for  making  applications/drivers  that  interface  with  the
  5.  specification provided that this paragraph and the Intel/Microsoft copyright
  6.  statement is maintained as is in the text and source code files.
  7.  
  8.  Copyright 1995 Microsoft, all rights reserved.
  9.  Portions copyright 1992, 1993 Intel/Microsoft, all rights reserved.
  10. }
  11.  
  12. { Converted to Delphi by Davide Moretti <dmoretti@iper.net> }
  13.  
  14. unit Tapi;
  15.  
  16. interface
  17.  
  18. {$IFDEF WIN32}
  19.   uses Windows, Messages;
  20. {$ELSE}
  21.   uses WinTypes, Messages;
  22. {$ENDIF}
  23.  
  24. { Type definitions of the data types used in tapi }
  25.  
  26. type
  27.   LPHCall = ^THCall;
  28.   THCall = Longint;
  29.   LPHLine = ^THLine;
  30.   THLine = Longint;
  31.   LPHPhone = ^THPhone;
  32.   THPhone = Longint;
  33.   LPHLineApp = ^THLineApp;
  34.   THLineApp = Longint;
  35.     LPHPhoneApp = ^THPhoneApp;
  36.   THPhoneApp = Longint;
  37.  
  38.   LPHIcon = ^HIcon;
  39.  
  40.  
  41. {
  42. // typedef of the LINE callback procedure
  43. typedef void (CALLBACK * LINECALLBACK)  (DWORD hDevice,
  44.                           DWORD dwMessage,
  45.                           DWORD dwInstance,
  46.                                                     DWORD dwParam1,
  47.                           DWORD dwParam2,
  48.                           DWORD dwParam3);
  49.  
  50. // typedef of the PHONE callback procedure
  51. typedef void (CALLBACK * PHONECALLBACK)  (DWORD hDevice,
  52.                            DWORD dwMessage,
  53.                            DWORD dwInstance,
  54.                            DWORD dwParam1,
  55.                            DWORD dwParam2,
  56.                            DWORD dwParam3);
  57. }
  58.  
  59. { Messages for Phones and Lines }
  60.  
  61. const
  62.   LINE_ADDRESSSTATE       = 0;
  63.   LINE_CALLINFO           = 1;
  64.   LINE_CALLSTATE          = 2;
  65.   LINE_CLOSE              = 3;
  66.   LINE_DEVSPECIFIC        = 4;
  67.   LINE_DEVSPECIFICFEATURE = 5;
  68.   LINE_GATHERDIGITS       = 6;
  69.   LINE_GENERATE           = 7;
  70.   LINE_LINEDEVSTATE       = 8;
  71.   LINE_MONITORDIGITS      = 9;
  72.   LINE_MONITORMEDIA       = 10;
  73.   LINE_MONITORTONE        = 11;
  74.   LINE_REPLY              = 12;
  75.   LINE_REQUEST            = 13;
  76.   PHONE_BUTTON            = 14;
  77.   PHONE_CLOSE             = 15;
  78.   PHONE_DEVSPECIFIC       = 16;
  79.   PHONE_REPLY             = 17;
  80.   PHONE_STATE             = 18;
  81.   LINE_CREATE             = 19;
  82.   PHONE_CREATE            = 20;
  83.  
  84. { Define Simple Telephony Constants. }
  85.  
  86.   TAPI_REPLY                  = Wm_User + 99;
  87.  
  88.   TAPIERR_CONNECTED           = 0;
  89.   TAPIERR_DROPPED             = -1;
  90.   TAPIERR_NOREQUESTRECIPIENT  = -2;
  91.   TAPIERR_REQUESTQUEUEFULL    = -3;
  92.   TAPIERR_INVALDESTADDRESS    = -4;
  93.   TAPIERR_INVALWINDOWHANDLE   = -5;
  94.   TAPIERR_INVALDEVICECLASS    = -6;
  95.   TAPIERR_INVALDEVICEID       = -7;
  96.   TAPIERR_DEVICECLASSUNAVAIL  = -8;
  97.   TAPIERR_DEVICEIDUNAVAIL     = -9;
  98.   TAPIERR_DEVICEINUSE         = -10;
  99.   TAPIERR_DESTBUSY            = -11;
  100.   TAPIERR_DESTNOANSWER        = -12;
  101.   TAPIERR_DESTUNAVAIL         = -13;
  102.   TAPIERR_UNKNOWNWINHANDLE    = -14;
  103.   TAPIERR_UNKNOWNREQUESTID    = -15;
  104.   TAPIERR_REQUESTFAILED       = -16;
  105.   TAPIERR_REQUESTCANCELLED    = -17;
  106.   TAPIERR_INVALPOINTER        = -18;
  107.  
  108.  
  109.   TAPIMAXDESTADDRESSSIZE  = 80;
  110.   TAPIMAXAPPNAMESIZE      = 40;
  111.   TAPIMAXCALLEDPARTYSIZE  = 40;
  112.   TAPIMAXCOMMENTSIZE      = 80;
  113.   TAPIMAXDEVICECLASSSIZE  = 40;
  114.   TAPIMAXDEVICEIDSIZE     = 40;
  115.  
  116.  
  117. { Data types and values for Phones }
  118.  
  119.  
  120.   PHONEBUTTONFUNCTION_UNKNOWN       = $00000000;
  121.   PHONEBUTTONFUNCTION_CONFERENCE    = $00000001;
  122.   PHONEBUTTONFUNCTION_TRANSFER      = $00000002;
  123.   PHONEBUTTONFUNCTION_DROP          = $00000003;
  124.   PHONEBUTTONFUNCTION_HOLD          = $00000004;
  125.   PHONEBUTTONFUNCTION_RECALL        = $00000005;
  126.   PHONEBUTTONFUNCTION_DISCONNECT    = $00000006;
  127.   PHONEBUTTONFUNCTION_CONNECT       = $00000007;
  128.   PHONEBUTTONFUNCTION_MSGWAITON     = $00000008;
  129.   PHONEBUTTONFUNCTION_MSGWAITOFF    = $00000009;
  130.   PHONEBUTTONFUNCTION_SELECTRING    = $0000000A;
  131.   PHONEBUTTONFUNCTION_ABBREVDIAL    = $0000000B;
  132.   PHONEBUTTONFUNCTION_FORWARD       = $0000000C;
  133.   PHONEBUTTONFUNCTION_PICKUP        = $0000000D;
  134.   PHONEBUTTONFUNCTION_RINGAGAIN     = $0000000E;
  135.   PHONEBUTTONFUNCTION_PARK          = $0000000F;
  136.   PHONEBUTTONFUNCTION_REJECT        = $00000010;
  137.   PHONEBUTTONFUNCTION_REDIRECT      = $00000011;
  138.   PHONEBUTTONFUNCTION_MUTE          = $00000012;
  139.   PHONEBUTTONFUNCTION_VOLUMEUP      = $00000013;
  140.   PHONEBUTTONFUNCTION_VOLUMEDOWN    = $00000014;
  141.   PHONEBUTTONFUNCTION_SPEAKERON     = $00000015;
  142.   PHONEBUTTONFUNCTION_SPEAKEROFF    = $00000016;
  143.   PHONEBUTTONFUNCTION_FLASH         = $00000017;
  144.   PHONEBUTTONFUNCTION_DATAON        = $00000018;
  145.   PHONEBUTTONFUNCTION_DATAOFF       = $00000019;
  146.   PHONEBUTTONFUNCTION_DONOTDISTURB  = $0000001A;
  147.   PHONEBUTTONFUNCTION_INTERCOM      = $0000001B;
  148.   PHONEBUTTONFUNCTION_BRIDGEDAPP    = $0000001C;
  149.   PHONEBUTTONFUNCTION_BUSY          = $0000001D;
  150.   PHONEBUTTONFUNCTION_CALLAPP       = $0000001E;
  151.   PHONEBUTTONFUNCTION_DATETIME      = $0000001F;
  152.   PHONEBUTTONFUNCTION_DIRECTORY     = $00000020;
  153.   PHONEBUTTONFUNCTION_COVER         = $00000021;
  154.   PHONEBUTTONFUNCTION_CALLID        = $00000022;
  155.   PHONEBUTTONFUNCTION_LASTNUM       = $00000023;
  156.   PHONEBUTTONFUNCTION_NIGHTSRV      = $00000024;
  157.   PHONEBUTTONFUNCTION_SENDCALLS     = $00000025;
  158.   PHONEBUTTONFUNCTION_MSGINDICATOR  = $00000026;
  159.   PHONEBUTTONFUNCTION_REPDIAL       = $00000027;
  160.   PHONEBUTTONFUNCTION_SETREPDIAL    = $00000028;
  161.   PHONEBUTTONFUNCTION_SYSTEMSPEED   = $00000029;
  162.   PHONEBUTTONFUNCTION_STATIONSPEED  = $0000002A;
  163.   PHONEBUTTONFUNCTION_CAMPON        = $0000002B;
  164.   PHONEBUTTONFUNCTION_SAVEREPEAT    = $0000002C;
  165.   PHONEBUTTONFUNCTION_QUEUECALL     = $0000002D;
  166.   PHONEBUTTONFUNCTION_NONE          = $0000002E;
  167.  
  168. type
  169.   LPPhoneButtonInfo = ^TPhoneButtonInfo;
  170.   TPhoneButtonInfo = record
  171.     dwTotalSize,
  172.     dwNeededSize,
  173.     dwUsedSize,
  174.  
  175.     dwButtonMode,
  176.     dwButtonFunction,
  177.  
  178.     dwButtonTextSize,
  179.     dwButtonTextOffset,
  180.  
  181.     dwDevSpecificSize,
  182.     dwDevSpecificOffset,
  183.  
  184.     dwButtonState: Longint;
  185.     end;
  186.  
  187. const
  188.   PHONEBUTTONMODE_DUMMY   = $00000001;
  189.   PHONEBUTTONMODE_CALL    = $00000002;
  190.   PHONEBUTTONMODE_FEATURE = $00000004;
  191.   PHONEBUTTONMODE_KEYPAD  = $00000008;
  192.   PHONEBUTTONMODE_LOCAL   = $00000010;
  193.   PHONEBUTTONMODE_DISPLAY = $00000020;
  194.  
  195.   PHONEBUTTONSTATE_UP      = $00000001;
  196.   PHONEBUTTONSTATE_DOWN    = $00000002;
  197.   PHONEBUTTONSTATE_UNKNOWN = $00000004;
  198.   PHONEBUTTONSTATE_UNAVAIL = $00000008;
  199.  
  200. type
  201.   LPPhoneExtensionID = ^TPhoneExtensionID;
  202.   TPhoneExtensionID = record
  203.     dwExtensionID0,
  204.     dwExtensionID1,
  205.     dwExtensionID2,
  206.     dwExtensionID3: Longint;
  207.     end;
  208.  
  209.   LPPhoneCaps = ^TPhoneCaps;
  210.   TPhoneCaps = record
  211.     dwTotalSize,
  212.     dwNeededSize,
  213.     dwUsedSize,
  214.  
  215.     dwProviderInfoSize,
  216.     dwProviderInfoOffset,
  217.  
  218.     dwPhoneInfoSize,
  219.     dwPhoneInfoOffset,
  220.  
  221.     dwPermanentPhoneID,
  222.     dwPhoneNameSize,
  223.     dwPhoneNameOffset,
  224.     dwStringFormat,
  225.  
  226.     dwPhoneStates,
  227.     dwHookSwitchDevs,
  228.     dwHandsetHookSwitchModes,
  229.     dwSpeakerHookSwitchModes,
  230.     dwHeadsetHookSwitchModes,
  231.  
  232.     dwVolumeFlags,
  233.     dwGainFlags,
  234.     dwDisplayNumRows,
  235.     dwDisplayNumColumns,
  236.     dwNumRingModes,
  237.     dwNumButtonLamps,
  238.  
  239.     dwButtonModesSize,
  240.     dwButtonModesOffset,
  241.  
  242.     dwButtonFunctionsSize,
  243.     dwButtonFunctionsOffset,
  244.  
  245.     dwLampModesSize,
  246.     dwLampModesOffset,
  247.  
  248.     dwNumSetData,
  249.     dwSetDataSize,
  250.     dwSetDataOffset,
  251.  
  252.     dwNumGetData,
  253.     dwGetDataSize,
  254.     dwGetDataOffset,
  255.  
  256.     dwDevSpecificSize,
  257.     dwDevSpecificOffset: Longint;
  258.     end;
  259.  
  260. const
  261.   PHONEERR_ALLOCATED              = $90000001;
  262.   PHONEERR_BADDEVICEID            = $90000002;
  263.   PHONEERR_INCOMPATIBLEAPIVERSION = $90000003;
  264.   PHONEERR_INCOMPATIBLEEXTVERSION = $90000004;
  265.   PHONEERR_INIFILECORRUPT         = $90000005;
  266.   PHONEERR_INUSE                  = $90000006;
  267.   PHONEERR_INVALAPPHANDLE         = $90000007;
  268.   PHONEERR_INVALAPPNAME           = $90000008;
  269.   PHONEERR_INVALBUTTONLAMPID      = $90000009;
  270.   PHONEERR_INVALBUTTONMODE        = $9000000A;
  271.   PHONEERR_INVALBUTTONSTATE       = $9000000B;
  272.   PHONEERR_INVALDATAID            = $9000000C;
  273.   PHONEERR_INVALDEVICECLASS       = $9000000D;
  274.   PHONEERR_INVALEXTVERSION        = $9000000E;
  275.   PHONEERR_INVALHOOKSWITCHDEV     = $9000000F;
  276.   PHONEERR_INVALHOOKSWITCHMODE    = $90000010;
  277.   PHONEERR_INVALLAMPMODE          = $90000011;
  278.   PHONEERR_INVALPARAM             = $90000012;
  279.   PHONEERR_INVALPHONEHANDLE       = $90000013;
  280.   PHONEERR_INVALPHONESTATE        = $90000014;
  281.   PHONEERR_INVALPOINTER           = $90000015;
  282.   PHONEERR_INVALPRIVILEGE         = $90000016;
  283.   PHONEERR_INVALRINGMODE          = $90000017;
  284.   PHONEERR_NODEVICE               = $90000018;
  285.   PHONEERR_NODRIVER               = $90000019;
  286.   PHONEERR_NOMEM                  = $9000001A;
  287.   PHONEERR_NOTOWNER               = $9000001B;
  288.   PHONEERR_OPERATIONFAILED        = $9000001C;
  289.   PHONEERR_OPERATIONUNAVAIL       = $9000001D;
  290.   PHONEERR_RESOURCEUNAVAIL        = $9000001F;
  291.   PHONEERR_REQUESTOVERRUN         = $90000020;
  292.   PHONEERR_STRUCTURETOOSMALL      = $90000021;
  293.   PHONEERR_UNINITIALIZED          = $90000022;
  294.   PHONEERR_REINIT                 = $90000023;
  295.  
  296.   PHONEHOOKSWITCHDEV_HANDSET  = $00000001;
  297.   PHONEHOOKSWITCHDEV_SPEAKER  = $00000002;
  298.   PHONEHOOKSWITCHDEV_HEADSET  = $00000004;
  299.  
  300.   PHONEHOOKSWITCHMODE_ONHOOK      = $00000001;
  301.   PHONEHOOKSWITCHMODE_MIC         = $00000002;
  302.   PHONEHOOKSWITCHMODE_SPEAKER     = $00000004;
  303.   PHONEHOOKSWITCHMODE_MICSPEAKER  = $00000008;
  304.   PHONEHOOKSWITCHMODE_UNKNOWN     = $00000010;
  305.  
  306.   PHONELAMPMODE_DUMMY         = $00000001;
  307.   PHONELAMPMODE_OFF           = $00000002;
  308.   PHONELAMPMODE_STEADY        = $00000004;
  309.   PHONELAMPMODE_WINK          = $00000008;
  310.   PHONELAMPMODE_FLASH         = $00000010;
  311.   PHONELAMPMODE_FLUTTER       = $00000020;
  312.   PHONELAMPMODE_BROKENFLUTTER = $00000040;
  313.   PHONELAMPMODE_UNKNOWN       = $00000080;
  314.  
  315.  
  316.   PHONEPRIVILEGE_MONITOR  = $00000001;
  317.   PHONEPRIVILEGE_OWNER    = $00000002;
  318.  
  319.   PHONESTATE_OTHER              = $00000001;
  320.   PHONESTATE_CONNECTED          = $00000002;
  321.   PHONESTATE_DISCONNECTED       = $00000004;
  322.   PHONESTATE_OWNER              = $00000008;
  323.   PHONESTATE_MONITORS           = $00000010;
  324.   PHONESTATE_DISPLAY            = $00000020;
  325.   PHONESTATE_LAMP               = $00000040;
  326.   PHONESTATE_RINGMODE           = $00000080;
  327.   PHONESTATE_RINGVOLUME         = $00000100;
  328.   PHONESTATE_HANDSETHOOKSWITCH  = $00000200;
  329.   PHONESTATE_HANDSETVOLUME      = $00000400;
  330.   PHONESTATE_HANDSETGAIN        = $00000800;
  331.   PHONESTATE_SPEAKERHOOKSWITCH  = $00001000;
  332.   PHONESTATE_SPEAKERVOLUME      = $00002000;
  333.   PHONESTATE_SPEAKERGAIN        = $00004000;
  334.   PHONESTATE_HEADSETHOOKSWITCH  = $00008000;
  335.   PHONESTATE_HEADSETVOLUME      = $00010000;
  336.   PHONESTATE_HEADSETGAIN        = $00020000;
  337.   PHONESTATE_SUSPEND            = $00040000;
  338.   PHONESTATE_RESUME             = $00080000;
  339.   PHONESTATE_DEVSPECIFIC        = $00100000;
  340.   PHONESTATE_REINIT             = $00200000;
  341.   PHONESTATE_CAPSCHANGE         = $00400000;
  342.   PHONESTATE_REMOVED            = $00800000;
  343.  
  344. type
  345.   LPPhoneStatus = ^TPhoneStatus;
  346.   TPhoneStatus = record
  347.     dwTotalSize,
  348.     dwNeededSize,
  349.     dwUsedSize,
  350.  
  351.     dwStatusFlags,
  352.     dwNumOwners,
  353.     dwNumMonitors,
  354.     dwRingMode,
  355.     dwRingVolume,
  356.  
  357.     dwHandsetHookSwitchMode,
  358.     dwHandsetVolume,
  359.     dwHandsetGain,
  360.  
  361.     dwSpeakerHookSwitchMode,
  362.     dwSpeakerVolume,
  363.     dwSpeakerGain,
  364.  
  365.     dwHeadsetHookSwitchMode,
  366.     dwHeadsetVolume,
  367.     dwHeadsetGain,
  368.  
  369.     dwDisplaySize,
  370.     dwDisplayOffset,
  371.  
  372.     dwLampModesSize,
  373.     dwLampModesOffset,
  374.  
  375.     dwOwnerNameSize,
  376.     dwOwnerNameOffset,
  377.  
  378.     dwDevSpecificSize,
  379.     dwDevSpecificOffset: Longint;
  380.     end;
  381.  
  382. const
  383.   PHONESTATUSFLAGS_CONNECTED  = $00000001;
  384.   PHONESTATUSFLAGS_SUSPENDED  = $00000002;
  385.  
  386.   STRINGFORMAT_ASCII   = $00000001;
  387.   STRINGFORMAT_DBCS    = $00000002;
  388.   STRINGFORMAT_UNICODE = $00000003;
  389.   STRINGFORMAT_BINARY  = $00000004;
  390.  
  391. type
  392.   LPVarString = ^TVarString;
  393.   TVarString = record
  394.     dwTotalSize,
  395.     dwNeededSize,
  396.     dwUsedSize,
  397.  
  398.     dwStringFormat,
  399.     dwStringSize,
  400.     dwStringOffset: Longint;
  401.     end;
  402.  
  403.  
  404. { Data types and values for Lines }
  405.  
  406. const
  407.   LINEADDRCAPFLAGS_FWDNUMRINGS      = $00000001;
  408.   LINEADDRCAPFLAGS_PICKUPGROUPID    = $00000002;
  409.   LINEADDRCAPFLAGS_SECURE           = $00000004;
  410.   LINEADDRCAPFLAGS_BLOCKIDDEFAULT   = $00000008;
  411.   LINEADDRCAPFLAGS_BLOCKIDOVERRIDE  = $00000010;
  412.   LINEADDRCAPFLAGS_DIALED           = $00000020;
  413.   LINEADDRCAPFLAGS_ORIGOFFHOOK      = $00000040;
  414.   LINEADDRCAPFLAGS_DESTOFFHOOK      = $00000080;
  415.   LINEADDRCAPFLAGS_FWDCONSULT       = $00000100;
  416.   LINEADDRCAPFLAGS_SETUPCONFNULL    = $00000200;
  417.   LINEADDRCAPFLAGS_AUTORECONNECT    = $00000400;
  418.   LINEADDRCAPFLAGS_COMPLETIONID     = $00000800;
  419.   LINEADDRCAPFLAGS_TRANSFERHELD     = $00001000;
  420.   LINEADDRCAPFLAGS_TRANSFERMAKE     = $00002000;
  421.   LINEADDRCAPFLAGS_CONFERENCEHELD   = $00004000;
  422.   LINEADDRCAPFLAGS_CONFERENCEMAKE   = $00008000;
  423.   LINEADDRCAPFLAGS_PARTIALDIAL      = $00010000;
  424.   LINEADDRCAPFLAGS_FWDSTATUSVALID   = $00020000;
  425.   LINEADDRCAPFLAGS_FWDINTEXTADDR    = $00040000;
  426.   LINEADDRCAPFLAGS_FWDBUSYNAADDR    = $00080000;
  427.   LINEADDRCAPFLAGS_ACCEPTTOALERT    = $00100000;
  428.   LINEADDRCAPFLAGS_CONFDROP         = $00200000;
  429.   LINEADDRCAPFLAGS_PICKUPCALLWAIT   = $00400000;
  430.  
  431. type
  432.   LPLineAddressCaps = ^TLineAddressCaps;
  433.   TLineAddressCaps = record
  434.     dwTotalSize,
  435.     dwNeededSize,
  436.     dwUsedSize,
  437.  
  438.     dwLineDeviceID,
  439.  
  440.     dwAddressSize,
  441.     dwAddressOffset,
  442.  
  443.     dwDevSpecificSize,
  444.     dwDevSpecificOffset,
  445.  
  446.     dwAddressSharing,
  447.     dwAddressStates,
  448.     dwCallInfoStates,
  449.     dwCallerIDFlags,
  450.     dwCalledIDFlags,
  451.     dwConnectedIDFlags,
  452.     dwRedirectionIDFlags,
  453.     dwRedirectingIDFlags,
  454.     dwCallStates,
  455.     dwDialToneModes,
  456.     dwBusyModes,
  457.     dwSpecialInfo,
  458.     dwDisconnectModes,
  459.  
  460.     dwMaxNumActiveCalls,
  461.     dwMaxNumOnHoldCalls,
  462.     dwMaxNumOnHoldPendingCalls,
  463.     dwMaxNumConference,
  464.     dwMaxNumTransConf,
  465.  
  466.     dwAddrCapFlags,
  467.     dwCallFeatures,
  468.     dwRemoveFromConfCaps,
  469.     dwRemoveFromConfState,
  470.     dwTransferModes,
  471.     dwParkModes,
  472.  
  473.     dwForwardModes,
  474.     dwMaxForwardEntries,
  475.     dwMaxSpecificEntries,
  476.     dwMinFwdNumRings,
  477.     dwMaxFwdNumRings,
  478.  
  479.     dwMaxCallCompletions,
  480.     dwCallCompletionConds,
  481.     dwCallCompletionModes,
  482.     dwNumCompletionMessages,
  483.     dwCompletionMsgTextEntrySize,
  484.     dwCompletionMsgTextSize,
  485.     dwCompletionMsgTextOffset,
  486.     dwAddressFeatures: Longint;
  487.     end;
  488.  
  489. const
  490.   LINEADDRESSMODE_ADDRESSID     = $00000001;
  491.   LINEADDRESSMODE_DIALABLEADDR  = $00000002;
  492.  
  493.  
  494.   LINEADDRESSSHARING_PRIVATE        = $00000001;
  495.   LINEADDRESSSHARING_BRIDGEDEXCL    = $00000002;
  496.   LINEADDRESSSHARING_BRIDGEDNEW     = $00000004;
  497.   LINEADDRESSSHARING_BRIDGEDSHARED  = $00000008;
  498.   LINEADDRESSSHARING_MONITORED      = $00000010;
  499.  
  500.   LINEADDRESSSTATE_OTHER        = $00000001;
  501.   LINEADDRESSSTATE_DEVSPECIFIC  = $00000002;
  502.   LINEADDRESSSTATE_INUSEZERO    = $00000004;
  503.   LINEADDRESSSTATE_INUSEONE     = $00000008;
  504.   LINEADDRESSSTATE_INUSEMANY    = $00000010;
  505.   LINEADDRESSSTATE_NUMCALLS     = $00000020;
  506.   LINEADDRESSSTATE_FORWARD      = $00000040;
  507.   LINEADDRESSSTATE_TERMINALS    = $00000080;
  508.   LINEADDRESSSTATE_CAPSCHANGE   = $00000100;
  509.  
  510. type
  511.   LPLineAddressStatus = ^TLineAddressStatus;
  512.   TLineAddressStatus = record
  513.     dwTotalSize,
  514.     dwNeededSize,
  515.     dwUsedSize,
  516.  
  517.     dwNumInUse,
  518.     dwNumActiveCalls,
  519.     dwNumOnHoldCalls,
  520.     dwNumOnHoldPendCalls,
  521.     dwAddressFeatures,
  522.  
  523.     dwNumRingsNoAnswer,
  524.     dwForwardNumEntries,
  525.     dwForwardSize,
  526.     dwForwardOffset,
  527.  
  528.     dwTerminalModesSize,
  529.     dwTerminalModesOffset,
  530.  
  531.     dwDevSpecificSize,
  532.     dwDevSpecificOffset: Longint;
  533.     end;
  534.  
  535. const
  536.   LINEADDRFEATURE_FORWARD         = $00000001;
  537.   LINEADDRFEATURE_MAKECALL        = $00000002;
  538.   LINEADDRFEATURE_PICKUP          = $00000004;
  539.   LINEADDRFEATURE_SETMEDIACONTROL = $00000008;
  540.   LINEADDRFEATURE_SETTERMINAL     = $00000010;
  541.   LINEADDRFEATURE_SETUPCONF       = $00000020;
  542.   LINEADDRFEATURE_UNCOMPLETECALL  = $00000040;
  543.   LINEADDRFEATURE_UNPARK          = $00000080;
  544.  
  545.  
  546.   LINEANSWERMODE_NONE = $00000001;
  547.   LINEANSWERMODE_DROP = $00000002;
  548.   LINEANSWERMODE_HOLD = $00000004;
  549.  
  550.   LINEBEARERMODE_VOICE            = $00000001;
  551.   LINEBEARERMODE_SPEECH           = $00000002;
  552.   LINEBEARERMODE_MULTIUSE         = $00000004;
  553.   LINEBEARERMODE_DATA             = $00000008;
  554.   LINEBEARERMODE_ALTSPEECHDATA    = $00000010;
  555.   LINEBEARERMODE_NONCALLSIGNALING = $00000020;
  556.   LINEBEARERMODE_PASSTHROUGH      = $00000040;
  557.  
  558.   LINEBUSYMODE_STATION  = $00000001;
  559.   LINEBUSYMODE_TRUNK    = $00000002;
  560.   LINEBUSYMODE_UNKNOWN  = $00000004;
  561.   LINEBUSYMODE_UNAVAIL  = $00000008;
  562.  
  563.   LINECALLCOMPLCOND_BUSY      = $00000001;
  564.   LINECALLCOMPLCOND_NOANSWER  = $00000002;
  565.  
  566.   LINECALLCOMPLMODE_CAMPON    = $00000001;
  567.   LINECALLCOMPLMODE_CALLBACK  = $00000002;
  568.   LINECALLCOMPLMODE_INTRUDE   = $00000004;
  569.   LINECALLCOMPLMODE_MESSAGE   = $00000008;
  570.  
  571.   LINECALLFEATURE_ACCEPT              = $00000001;
  572.   LINECALLFEATURE_ADDTOCONF           = $00000002;
  573.   LINECALLFEATURE_ANSWER              = $00000004;
  574.   LINECALLFEATURE_BLINDTRANSFER       = $00000008;
  575.   LINECALLFEATURE_COMPLETECALL        = $00000010;
  576.   LINECALLFEATURE_COMPLETETRANSF      = $00000020;
  577.   LINECALLFEATURE_DIAL                = $00000040;
  578.   LINECALLFEATURE_DROP                = $00000080;
  579.   LINECALLFEATURE_GATHERDIGITS        = $00000100;
  580.   LINECALLFEATURE_GENERATEDIGITS      = $00000200;
  581.   LINECALLFEATURE_GENERATETONE        = $00000400;
  582.   LINECALLFEATURE_HOLD                = $00000800;
  583.   LINECALLFEATURE_MONITORDIGITS       = $00001000;
  584.   LINECALLFEATURE_MONITORMEDIA        = $00002000;
  585.   LINECALLFEATURE_MONITORTONES        = $00004000;
  586.   LINECALLFEATURE_PARK                = $00008000;
  587.   LINECALLFEATURE_PREPAREADDCONF      = $00010000;
  588.   LINECALLFEATURE_REDIRECT            = $00020000;
  589.   LINECALLFEATURE_REMOVEFROMCONF      = $00040000;
  590.   LINECALLFEATURE_SECURECALL          = $00080000;
  591.   LINECALLFEATURE_SENDUSERUSER        = $00100000;
  592.   LINECALLFEATURE_SETCALLPARAMS       = $00200000;
  593.   LINECALLFEATURE_SETMEDIACONTROL     = $00400000;
  594.   LINECALLFEATURE_SETTERMINAL         = $00800000;
  595.   LINECALLFEATURE_SETUPCONF           = $01000000;
  596.   LINECALLFEATURE_SETUPTRANSFER       = $02000000;
  597.   LINECALLFEATURE_SWAPHOLD            = $04000000;
  598.   LINECALLFEATURE_UNHOLD              = $08000000;
  599.   LINECALLFEATURE_RELEASEUSERUSERINFO = $10000000;
  600.  
  601. type
  602.   LPLineDialParams = ^TLineDialParams;
  603.   TLineDialParams = record
  604.     dwDialPause,
  605.     dwDialSpeed,
  606.     dwDigitDuration,
  607.     dwWaitForDialtone: Longint;
  608.     end;
  609.  
  610.   LPLineCallInfo = ^TLineCallInfo;
  611.   TLineCallInfo = record
  612.     dwTotalSize,
  613.     dwNeededSize,
  614.     dwUsedSize: Longint;
  615.  
  616.     hLine: THLine;
  617.     dwLineDeviceID,
  618.     dwAddressID,
  619.  
  620.     dwBearerMode,
  621.     dwRate,
  622.     dwMediaMode,
  623.  
  624.     dwAppSpecific,
  625.     dwCallID,
  626.     dwRelatedCallID,
  627.     dwCallParamFlags,
  628.     dwCallStates,
  629.  
  630.     dwMonitorDigitModes,
  631.     dwMonitorMediaModes: Longint;
  632.     DialParams: TLineDialParams;
  633.  
  634.     dwOrigin,
  635.     dwReason,
  636.     dwCompletionID,
  637.     dwNumOwners,
  638.     dwNumMonitors,
  639.  
  640.     dwCountryCode,
  641.     dwTrunk,
  642.  
  643.     dwCallerIDFlags,
  644.     dwCallerIDSize,
  645.     dwCallerIDOffset,
  646.     dwCallerIDNameSize,
  647.     dwCallerIDNameOffset,
  648.  
  649.     dwCalledIDFlags,
  650.     dwCalledIDSize,
  651.     dwCalledIDOffset,
  652.     dwCalledIDNameSize,
  653.     dwCalledIDNameOffset,
  654.  
  655.     dwConnectedIDFlags,
  656.     dwConnectedIDSize,
  657.     dwConnectedIDOffset,
  658.     dwConnectedIDNameSize,
  659.     dwConnectedIDNameOffset,
  660.  
  661.     dwRedirectionIDFlags,
  662.     dwRedirectionIDSize,
  663.     dwRedirectionIDOffset,
  664.     dwRedirectionIDNameSize,
  665.     dwRedirectionIDNameOffset,
  666.  
  667.     dwRedirectingIDFlags,
  668.     dwRedirectingIDSize,
  669.     dwRedirectingIDOffset,
  670.     dwRedirectingIDNameSize,
  671.     dwRedirectingIDNameOffset,
  672.  
  673.     dwAppNameSize,
  674.     dwAppNameOffset,
  675.  
  676.     dwDisplayableAddressSize,
  677.     dwDisplayableAddressOffset,
  678.  
  679.     dwCalledPartySize,
  680.     dwCalledPartyOffset,
  681.  
  682.     dwCommentSize,
  683.     dwCommentOffset,
  684.  
  685.     dwDisplaySize,
  686.     dwDisplayOffset,
  687.  
  688.     dwUserUserInfoSize,
  689.     dwUserUserInfoOffset,
  690.  
  691.     dwHighLevelCompSize,
  692.     dwHighLevelCompOffset,
  693.  
  694.     dwLowLevelCompSize,
  695.     dwLowLevelCompOffset,
  696.  
  697.     dwChargingInfoSize,
  698.     dwChargingInfoOffset,
  699.  
  700.     dwTerminalModesSize,
  701.     dwTerminalModesOffset,
  702.  
  703.     dwDevSpecificSize,
  704.     dwDevSpecificOffset: Longint;
  705.     end;
  706.  
  707. const
  708.   LINECALLINFOSTATE_OTHER         = $00000001;
  709.   LINECALLINFOSTATE_DEVSPECIFIC   = $00000002;
  710.   LINECALLINFOSTATE_BEARERMODE    = $00000004;
  711.   LINECALLINFOSTATE_RATE          = $00000008;
  712.   LINECALLINFOSTATE_MEDIAMODE     = $00000010;
  713.   LINECALLINFOSTATE_APPSPECIFIC   = $00000020;
  714.   LINECALLINFOSTATE_CALLID        = $00000040;
  715.   LINECALLINFOSTATE_RELATEDCALLID = $00000080;
  716.   LINECALLINFOSTATE_ORIGIN        = $00000100;
  717.   LINECALLINFOSTATE_REASON        = $00000200;
  718.   LINECALLINFOSTATE_COMPLETIONID  = $00000400;
  719.   LINECALLINFOSTATE_NUMOWNERINCR  = $00000800;
  720.   LINECALLINFOSTATE_NUMOWNERDECR  = $00001000;
  721.   LINECALLINFOSTATE_NUMMONITORS   = $00002000;
  722.   LINECALLINFOSTATE_TRUNK         = $00004000;
  723.   LINECALLINFOSTATE_CALLERID      = $00008000;
  724.   LINECALLINFOSTATE_CALLEDID      = $00010000;
  725.   LINECALLINFOSTATE_CONNECTEDID   = $00020000;
  726.   LINECALLINFOSTATE_REDIRECTIONID = $00040000;
  727.   LINECALLINFOSTATE_REDIRECTINGID = $00080000;
  728.   LINECALLINFOSTATE_DISPLAY       = $00100000;
  729.   LINECALLINFOSTATE_USERUSERINFO  = $00200000;
  730.   LINECALLINFOSTATE_HIGHLEVELCOMP = $00400000;
  731.   LINECALLINFOSTATE_LOWLEVELCOMP  = $00800000;
  732.   LINECALLINFOSTATE_CHARGINGINFO  = $01000000;
  733.   LINECALLINFOSTATE_TERMINAL      = $02000000;
  734.   LINECALLINFOSTATE_DIALPARAMS    = $04000000;
  735.   LINECALLINFOSTATE_MONITORMODES  = $08000000;
  736.  
  737. type
  738.   LPLineCallList = ^TLineCallList;
  739.   TLineCallList = record
  740.     dwTotalSize,
  741.     dwNeededSize,
  742.     dwUsedSize,
  743.  
  744.     dwCallsNumEntries,
  745.     dwCallsSize,
  746.     dwCallsOffset: Longint;
  747.     end;
  748.  
  749. const
  750.   LINECALLORIGIN_OUTBOUND   = $00000001;
  751.   LINECALLORIGIN_INTERNAL   = $00000002;
  752.   LINECALLORIGIN_EXTERNAL   = $00000004;
  753.   LINECALLORIGIN_UNKNOWN    = $00000010;
  754.   LINECALLORIGIN_UNAVAIL    = $00000020;
  755.   LINECALLORIGIN_CONFERENCE = $00000040;
  756.   LINECALLORIGIN_INBOUND    = $00000080;
  757.  
  758.   LINECALLPARAMFLAGS_SECURE       = $00000001;
  759.   LINECALLPARAMFLAGS_IDLE         = $00000002;
  760.   LINECALLPARAMFLAGS_BLOCKID      = $00000004;
  761.   LINECALLPARAMFLAGS_ORIGOFFHOOK  = $00000008;
  762.   LINECALLPARAMFLAGS_DESTOFFHOOK  = $00000010;
  763.  
  764. type
  765.   LPLineCallParams = ^TLineCallParams;
  766.   TLineCallParams = record              { Defaults: }
  767.     dwTotalSize,                        { --------- }
  768.  
  769.     dwBearerMode,                       { voice }
  770.     dwMinRate,                          { (3.1kHz) }
  771.     dwMaxRate,                          { (3.1kHz) }
  772.     dwMediaMode,                        { interactiveVoice }
  773.  
  774.     dwCallParamFlags,                   { 0 }
  775.     dwAddressMode,                      { addressID }
  776.     dwAddressID: Longint;               { (any available) }
  777.  
  778.     DialParams: TLineDialParams;        { (0, 0, 0, 0) }
  779.  
  780.     dwOrigAddressSize,                  { 0 }
  781.     dwOrigAddressOffset,
  782.     dwDisplayableAddressSize,
  783.     dwDisplayableAddressOffset,
  784.  
  785.     dwCalledPartySize,                  { 0 }
  786.     dwCalledPartyOffset,
  787.  
  788.     dwCommentSize,                      { 0 }
  789.     dwCommentOffset,
  790.  
  791.     dwUserUserInfoSize,                 { 0 }
  792.     dwUserUserInfoOffset,
  793.  
  794.     dwHighLevelCompSize,                { 0 }
  795.     dwHighLevelCompOffset,
  796.  
  797.     dwLowLevelCompSize,                 { 0 }
  798.     dwLowLevelCompOffset,
  799.  
  800.     dwDevSpecificSize,                  { 0 }
  801.     dwDevSpecificOffset: Longint;
  802.     end;
  803.  
  804. const
  805.   LINECALLPARTYID_BLOCKED       = $00000001;
  806.   LINECALLPARTYID_OUTOFAREA     = $00000002;
  807.   LINECALLPARTYID_NAME          = $00000004;
  808.   LINECALLPARTYID_ADDRESS       = $00000008;
  809.   LINECALLPARTYID_PARTIAL       = $00000010;
  810.   LINECALLPARTYID_UNKNOWN       = $00000020;
  811.   LINECALLPARTYID_UNAVAIL       = $00000040;
  812.  
  813.   LINECALLPRIVILEGE_NONE        = $00000001;
  814.   LINECALLPRIVILEGE_MONITOR     = $00000002;
  815.   LINECALLPRIVILEGE_OWNER       = $00000004;
  816.  
  817.   LINECALLREASON_DIRECT         = $00000001;
  818.   LINECALLREASON_FWDBUSY        = $00000002;
  819.   LINECALLREASON_FWDNOANSWER    = $00000004;
  820.   LINECALLREASON_FWDUNCOND      = $00000008;
  821.   LINECALLREASON_PICKUP         = $00000010;
  822.   LINECALLREASON_UNPARK         = $00000020;
  823.   LINECALLREASON_REDIRECT       = $00000040;
  824.   LINECALLREASON_CALLCOMPLETION = $00000080;
  825.   LINECALLREASON_TRANSFER       = $00000100;
  826.   LINECALLREASON_REMINDER       = $00000200;
  827.   LINECALLREASON_UNKNOWN        = $00000400;
  828.   LINECALLREASON_UNAVAIL        = $00000800;
  829.   LINECALLREASON_INTRUDE        = $00001000;
  830.   LINECALLREASON_PARKED         = $00002000;
  831.  
  832.   LINECALLSELECT_LINE     = $00000001;
  833.   LINECALLSELECT_ADDRESS  = $00000002;
  834.   LINECALLSELECT_CALL     = $00000004;
  835.  
  836.   LINECALLSTATE_IDLE                = $00000001;
  837.   LINECALLSTATE_OFFERING            = $00000002;
  838.   LINECALLSTATE_ACCEPTED            = $00000004;
  839.   LINECALLSTATE_DIALTONE            = $00000008;
  840.   LINECALLSTATE_DIALING             = $00000010;
  841.   LINECALLSTATE_RINGBACK            = $00000020;
  842.   LINECALLSTATE_BUSY                = $00000040;
  843.   LINECALLSTATE_SPECIALINFO         = $00000080;
  844.   LINECALLSTATE_CONNECTED           = $00000100;
  845.   LINECALLSTATE_PROCEEDING          = $00000200;
  846.   LINECALLSTATE_ONHOLD              = $00000400;
  847.   LINECALLSTATE_CONFERENCED         = $00000800;
  848.   LINECALLSTATE_ONHOLDPENDCONF      = $00001000;
  849.   LINECALLSTATE_ONHOLDPENDTRANSFER  = $00002000;
  850.   LINECALLSTATE_DISCONNECTED        = $00004000;
  851.   LINECALLSTATE_UNKNOWN             = $00008000;
  852.  
  853.  
  854.   LINECONNECTEDMODE_ACTIVE    = $00000001;
  855.   LINECONNECTEDMODE_INACTIVE  = $00000002;
  856.  
  857.   LINEOFFERINGMODE_ACTIVE   = $00000001;
  858.   LINEOFFERINGMODE_INACTIVE = $00000002;
  859.  
  860.  
  861. type
  862.   LPLineCallStatus = ^TLineCallStatus;
  863.   TLineCallStatus = record
  864.     dwTotalSize,
  865.     dwNeededSize,
  866.     dwUsedSize,
  867.  
  868.     dwCallState,
  869.     dwCallStateMode,
  870.     dwCallPrivilege,
  871.     dwCallFeatures,
  872.  
  873.     dwDevSpecificSize,
  874.     dwDevSpecificOffset: Longint;
  875.     end;
  876.  
  877. const
  878.   LINEDEVCAPFLAGS_CROSSADDRCONF = $00000001;
  879.   LINEDEVCAPFLAGS_HIGHLEVCOMP   = $00000002;
  880.   LINEDEVCAPFLAGS_LOWLEVCOMP    = $00000004;
  881.   LINEDEVCAPFLAGS_MEDIACONTROL  = $00000008;
  882.   LINEDEVCAPFLAGS_MULTIPLEADDR  = $00000010;
  883.   LINEDEVCAPFLAGS_CLOSEDROP     = $00000020;
  884.   LINEDEVCAPFLAGS_DIALBILLING   = $00000040;
  885.   LINEDEVCAPFLAGS_DIALQUIET     = $00000080;
  886.   LINEDEVCAPFLAGS_DIALDIALTONE  = $00000100;
  887.  
  888. type
  889.   LPLineExtensionID = ^TLineExtensionID;
  890.   TLineExtensionID = record
  891.     dwExtensionID0,
  892.     dwExtensionID1,
  893.     dwExtensionID2,
  894.     dwExtensionID3: Longint;
  895.     end;
  896.  
  897.   LPLineDevCaps = ^TLineDevCaps;
  898.   TLineDevCaps = record
  899.     dwTotalSize,
  900.     dwNeededSize,
  901.     dwUsedSize,
  902.  
  903.     dwProviderInfoSize,
  904.     dwProviderInfoOffset,
  905.  
  906.     dwSwitchInfoSize,
  907.     dwSwitchInfoOffset,
  908.  
  909.     dwPermanentLineID,
  910.     dwLineNameSize,
  911.     dwLineNameOffset,
  912.     dwStringFormat,
  913.  
  914.     dwAddressModes,
  915.     dwNumAddresses,
  916.     dwBearerModes,
  917.     dwMaxRate,
  918.     dwMediaModes,
  919.  
  920.     dwGenerateToneModes,
  921.     dwGenerateToneMaxNumFreq,
  922.     dwGenerateDigitModes,
  923.     dwMonitorToneMaxNumFreq,
  924.     dwMonitorToneMaxNumEntries,
  925.     dwMonitorDigitModes,
  926.     dwGatherDigitsMinTimeout,
  927.     dwGatherDigitsMaxTimeout,
  928.  
  929.     dwMedCtlDigitMaxListSize,
  930.     dwMedCtlMediaMaxListSize,
  931.     dwMedCtlToneMaxListSize,
  932.     dwMedCtlCallStateMaxListSize,
  933.  
  934.     dwDevCapFlags,
  935.     dwMaxNumActiveCalls,
  936.     dwAnswerMode,
  937.     dwRingModes,
  938.     dwLineStates,
  939.  
  940.     dwUUIAcceptSize,
  941.     dwUUIAnswerSize,
  942.     dwUUIMakeCallSize,
  943.     dwUUIDropSize,
  944.     dwUUISendUserUserInfoSize,
  945.     dwUUICallInfoSize: Longint;
  946.  
  947.     MinDialParams,
  948.     MaxDialParams,
  949.     DefaultDialParams: TLineDialParams;
  950.  
  951.     dwNumTerminals,
  952.     dwTerminalCapsSize,
  953.     dwTerminalCapsOffset,
  954.     dwTerminalTextEntrySize,
  955.     dwTerminalTextSize,
  956.     dwTerminalTextOffset,
  957.  
  958.     dwDevSpecificSize,
  959.     dwDevSpecificOffset,
  960.     dwLineFeatures: Longint;
  961.     end;
  962.  
  963. const
  964.   LINEDEVSTATE_OTHER            = $00000001;
  965.   LINEDEVSTATE_RINGING          = $00000002;
  966.   LINEDEVSTATE_CONNECTED        = $00000004;
  967.   LINEDEVSTATE_DISCONNECTED     = $00000008;
  968.   LINEDEVSTATE_MSGWAITON        = $00000010;
  969.   LINEDEVSTATE_MSGWAITOFF       = $00000020;
  970.   LINEDEVSTATE_INSERVICE        = $00000040;
  971.   LINEDEVSTATE_OUTOFSERVICE     = $00000080;
  972.   LINEDEVSTATE_MAINTENANCE      = $00000100;
  973.   LINEDEVSTATE_OPEN             = $00000200;
  974.   LINEDEVSTATE_CLOSE            = $00000400;
  975.   LINEDEVSTATE_NUMCALLS         = $00000800;
  976.   LINEDEVSTATE_NUMCOMPLETIONS   = $00001000;
  977.   LINEDEVSTATE_TERMINALS        = $00002000;
  978.   LINEDEVSTATE_ROAMMODE         = $00004000;
  979.   LINEDEVSTATE_BATTERY          = $00008000;
  980.   LINEDEVSTATE_SIGNAL           = $00010000;
  981.   LINEDEVSTATE_DEVSPECIFIC      = $00020000;
  982.   LINEDEVSTATE_REINIT           = $00040000;
  983.   LINEDEVSTATE_LOCK             = $00080000;
  984.   LINEDEVSTATE_CAPSCHANGE       = $00100000;
  985.   LINEDEVSTATE_CONFIGCHANGE     = $00200000;
  986.   LINEDEVSTATE_TRANSLATECHANGE  = $00400000;
  987.   LINEDEVSTATE_COMPLCANCEL      = $00800000;
  988.   LINEDEVSTATE_REMOVED          = $01000000;
  989.  
  990. type
  991.   LPLineDevStatus = ^TLineDevStatus;
  992.   TLineDevStatus = record
  993.     dwTotalSize,
  994.     dwNeededSize,
  995.     dwUsedSize,
  996.  
  997.     dwNumOpens,
  998.     dwOpenMediaModes,
  999.     dwNumActiveCalls,
  1000.     dwNumOnHoldCalls,
  1001.     dwNumOnHoldPendCalls,
  1002.     dwLineFeatures,
  1003.     dwNumCallCompletions,
  1004.     dwRingMode,
  1005.     dwSignalLevel,
  1006.     dwBatteryLevel,
  1007.     dwRoamMode,
  1008.  
  1009.     dwDevStatusFlags,
  1010.  
  1011.     dwTerminalModesSize,
  1012.     dwTerminalModesOffset,
  1013.  
  1014.     dwDevSpecificSize,
  1015.     dwDevSpecificOffset: Longint;
  1016.     end;
  1017.  
  1018. const
  1019.   LINEDEVSTATUSFLAGS_CONNECTED  = $00000001;
  1020.   LINEDEVSTATUSFLAGS_MSGWAIT    = $00000002;
  1021.   LINEDEVSTATUSFLAGS_INSERVICE  = $00000004;
  1022.   LINEDEVSTATUSFLAGS_LOCKED     = $00000008;
  1023.  
  1024.  
  1025.   LINEDIALTONEMODE_NORMAL   = $00000001;
  1026.   LINEDIALTONEMODE_SPECIAL  = $00000002;
  1027.   LINEDIALTONEMODE_INTERNAL = $00000004;
  1028.   LINEDIALTONEMODE_EXTERNAL = $00000008;
  1029.   LINEDIALTONEMODE_UNKNOWN  = $00000010;
  1030.   LINEDIALTONEMODE_UNAVAIL  = $00000020;
  1031.  
  1032.   LINEDIGITMODE_PULSE   = $00000001;
  1033.   LINEDIGITMODE_DTMF    = $00000002;
  1034.   LINEDIGITMODE_DTMFEND = $00000004;
  1035.  
  1036.   LINEDISCONNECTMODE_NORMAL       = $00000001;
  1037.   LINEDISCONNECTMODE_UNKNOWN      = $00000002;
  1038.   LINEDISCONNECTMODE_REJECT       = $00000004;
  1039.   LINEDISCONNECTMODE_PICKUP       = $00000008;
  1040.   LINEDISCONNECTMODE_FORWARDED    = $00000010;
  1041.   LINEDISCONNECTMODE_BUSY         = $00000020;
  1042.   LINEDISCONNECTMODE_NOANSWER     = $00000040;
  1043.   LINEDISCONNECTMODE_BADADDRESS   = $00000080;
  1044.   LINEDISCONNECTMODE_UNREACHABLE  = $00000100;
  1045.   LINEDISCONNECTMODE_CONGESTION   = $00000200;
  1046.   LINEDISCONNECTMODE_INCOMPATIBLE = $00000400;
  1047.   LINEDISCONNECTMODE_UNAVAIL      = $00000800;
  1048.   LINEDISCONNECTMODE_NODIALTONE   = $00001000;
  1049.  
  1050.   LINEERR_ALLOCATED               = $80000001;
  1051.   LINEERR_BADDEVICEID             = $80000002;
  1052.   LINEERR_BEARERMODEUNAVAIL       = $80000003;
  1053.   LINEERR_CALLUNAVAIL             = $80000005;
  1054.   LINEERR_COMPLETIONOVERRUN       = $80000006;
  1055.   LINEERR_CONFERENCEFULL          = $80000007;
  1056.   LINEERR_DIALBILLING             = $80000008;
  1057.   LINEERR_DIALDIALTONE            = $80000009;
  1058.   LINEERR_DIALPROMPT              = $8000000A;
  1059.   LINEERR_DIALQUIET               = $8000000B;
  1060.   LINEERR_INCOMPATIBLEAPIVERSION  = $8000000C;
  1061.   LINEERR_INCOMPATIBLEEXTVERSION  = $8000000D;
  1062.   LINEERR_INIFILECORRUPT          = $8000000E;
  1063.   LINEERR_INUSE                   = $8000000F;
  1064.   LINEERR_INVALADDRESS            = $80000010;
  1065.   LINEERR_INVALADDRESSID          = $80000011;
  1066.   LINEERR_INVALADDRESSMODE        = $80000012;
  1067.   LINEERR_INVALADDRESSSTATE       = $80000013;
  1068.   LINEERR_INVALAPPHANDLE          = $80000014;
  1069.   LINEERR_INVALAPPNAME            = $80000015;
  1070.   LINEERR_INVALBEARERMODE         = 80000016;
  1071.   LINEERR_INVALCALLCOMPLMODE      = $80000017;
  1072.   LINEERR_INVALCALLHANDLE         = $80000018;
  1073.   LINEERR_INVALCALLPARAMS         = $80000019;
  1074.   LINEERR_INVALCALLPRIVILEGE      = $8000001A;
  1075.   LINEERR_INVALCALLSELECT         = $8000001B;
  1076.   LINEERR_INVALCALLSTATE          = $8000001C;
  1077.   LINEERR_INVALCALLSTATELIST      = $8000001D;
  1078.   LINEERR_INVALCARD               = $8000001E;
  1079.   LINEERR_INVALCOMPLETIONID       = $8000001F;
  1080.   LINEERR_INVALCONFCALLHANDLE     = $80000020;
  1081.   LINEERR_INVALCONSULTCALLHANDLE  = $80000021;
  1082.   LINEERR_INVALCOUNTRYCODE        = $80000022;
  1083.   LINEERR_INVALDEVICECLASS        = $80000023;
  1084.   LINEERR_INVALDEVICEHANDLE       = $80000024;
  1085.   LINEERR_INVALDIALPARAMS         = $80000025;
  1086.   LINEERR_INVALDIGITLIST          = $80000026;
  1087.   LINEERR_INVALDIGITMODE          = $80000027;
  1088.   LINEERR_INVALDIGITS             = $80000028;
  1089.   LINEERR_INVALEXTVERSION         = $80000029;
  1090.   LINEERR_INVALGROUPID            = $8000002A;
  1091.   LINEERR_INVALLINEHANDLE         = $8000002B;
  1092.   LINEERR_INVALLINESTATE          = $8000002C;
  1093.   LINEERR_INVALLOCATION           = $8000002D;
  1094.   LINEERR_INVALMEDIALIST          = $8000002E;
  1095.   LINEERR_INVALMEDIAMODE          = $8000002F;
  1096.   LINEERR_INVALMESSAGEID          = $80000030;
  1097.   LINEERR_INVALPARAM              = $80000032;
  1098.   LINEERR_INVALPARKID             = $80000033;
  1099.   LINEERR_INVALPARKMODE           = $80000034;
  1100.   LINEERR_INVALPOINTER            = $80000035;
  1101.   LINEERR_INVALPRIVSELECT         = $80000036;
  1102.   LINEERR_INVALRATE               = $80000037;
  1103.   LINEERR_INVALREQUESTMODE        = $80000038;
  1104.   LINEERR_INVALTERMINALID         = $80000039;
  1105.   LINEERR_INVALTERMINALMODE       = $8000003A;
  1106.   LINEERR_INVALTIMEOUT            = $8000003B;
  1107.   LINEERR_INVALTONE               = $8000003C;
  1108.   LINEERR_INVALTONELIST           = $8000003D;
  1109.   LINEERR_INVALTONEMODE           = $8000003E;
  1110.   LINEERR_INVALTRANSFERMODE       = $8000003F;
  1111.   LINEERR_LINEMAPPERFAILED        = $80000040;
  1112.   LINEERR_NOCONFERENCE            = $80000041;
  1113.   LINEERR_NODEVICE                = $80000042;
  1114.   LINEERR_NODRIVER                = $80000043;
  1115.   LINEERR_NOMEM                   = $80000044;
  1116.   LINEERR_NOREQUEST               = $80000045;
  1117.   LINEERR_NOTOWNER                = $80000046;
  1118.   LINEERR_NOTREGISTERED           = $80000047;
  1119.   LINEERR_OPERATIONFAILED         = $80000048;
  1120.   LINEERR_OPERATIONUNAVAIL        = $80000049;
  1121.   LINEERR_RATEUNAVAIL             = $8000004A;
  1122.   LINEERR_RESOURCEUNAVAIL         = $8000004B;
  1123.   LINEERR_REQUESTOVERRUN          = $8000004C;
  1124.   LINEERR_STRUCTURETOOSMALL       = $8000004D;
  1125.   LINEERR_TARGETNOTFOUND          = $8000004E;
  1126.   LINEERR_TARGETSELF              = $8000004F;
  1127.   LINEERR_UNINITIALIZED           = $80000050;
  1128.   LINEERR_USERUSERINFOTOOBIG      = $80000051;
  1129.   LINEERR_REINIT                  = $80000052;
  1130.   LINEERR_ADDRESSBLOCKED          = $80000053;
  1131.   LINEERR_BILLINGREJECTED         = $80000054;
  1132.   LINEERR_INVALFEATURE            = $80000055;
  1133.   LINEERR_NOMULTIPLEINSTANCE      = $80000056;
  1134.  
  1135.   LINEFEATURE_DEVSPECIFIC     = $00000001;
  1136.   LINEFEATURE_DEVSPECIFICFEAT = $00000002;
  1137.   LINEFEATURE_FORWARD         = $00000004;
  1138.   LINEFEATURE_MAKECALL        = $00000008;
  1139.   LINEFEATURE_SETMEDIACONTROL = $00000010;
  1140.   LINEFEATURE_SETTERMINAL     = $00000020;
  1141.  
  1142. type
  1143.   LPLineForward = ^TLineForward;
  1144.   TLineForward = record
  1145.     dwForwardMode,
  1146.  
  1147.     dwCallerAddressSize,
  1148.     dwCallerAddressOffset,
  1149.  
  1150.     dwDestCountryCode,
  1151.     dwDestAddressSize,
  1152.     dwDestAddressOffset: Longint;
  1153.     end;
  1154.  
  1155.  
  1156.   LPLineForwardList = ^TLineForwardList;
  1157.   TLineForwardList = record
  1158.     dwTotalSize: Longint;
  1159.  
  1160.     dwNumEntries: Longint;
  1161.     ForwardList: array[0..0] of TLineForward;
  1162.     end;
  1163.  
  1164. const
  1165.   LINEFORWARDMODE_UNCOND          = $00000001;
  1166.   LINEFORWARDMODE_UNCONDINTERNAL  = $00000002;
  1167.   LINEFORWARDMODE_UNCONDEXTERNAL  = $00000004;
  1168.   LINEFORWARDMODE_UNCONDSPECIFIC  = $00000008;
  1169.   LINEFORWARDMODE_BUSY            = $00000010;
  1170.   LINEFORWARDMODE_BUSYINTERNAL    = $00000020;
  1171.   LINEFORWARDMODE_BUSYEXTERNAL    = $00000040;
  1172.   LINEFORWARDMODE_BUSYSPECIFIC    = $00000080;
  1173.   LINEFORWARDMODE_NOANSW          = $00000100;
  1174.   LINEFORWARDMODE_NOANSWINTERNAL  = $00000200;
  1175.   LINEFORWARDMODE_NOANSWEXTERNAL  = $00000400;
  1176.   LINEFORWARDMODE_NOANSWSPECIFIC  = $00000800;
  1177.   LINEFORWARDMODE_BUSYNA          = $00001000;
  1178.   LINEFORWARDMODE_BUSYNAINTERNAL  = $00002000;
  1179.   LINEFORWARDMODE_BUSYNAEXTERNAL  = $00004000;
  1180.   LINEFORWARDMODE_BUSYNASPECIFIC  = $00008000;
  1181.   LINEFORWARDMODE_UNKNOWN         = $00010000;
  1182.   LINEFORWARDMODE_UNAVAIL         = $00020000;
  1183.  
  1184.   LINEGATHERTERM_BUFFERFULL   = $00000001;
  1185.   LINEGATHERTERM_TERMDIGIT    = $00000002;
  1186.   LINEGATHERTERM_FIRSTTIMEOUT = $00000004;
  1187.   LINEGATHERTERM_INTERTIMEOUT = $00000008;
  1188.   LINEGATHERTERM_CANCEL       = $00000010;
  1189.  
  1190.   LINEGENERATETERM_DONE   = $00000001;
  1191.   LINEGENERATETERM_CANCEL = $00000002;
  1192.  
  1193. type
  1194.   LPLineGenerateTone = ^TLineGenerateTone;
  1195.   TLineGenerateTone = record
  1196.     dwFrequency,
  1197.     dwCadenceOn,
  1198.     dwCadenceOff,
  1199.     dwVolume: Longint;
  1200.     end;
  1201.  
  1202. const
  1203.   LINEMAPPER = $FFFFFFFF;
  1204.  
  1205. type
  1206.   LPLineMediaControlCallState = ^TLineMediaControlCallState;
  1207.   TLineMediaControlCallState = record
  1208.     dwCallStates,
  1209.     dwMediaControl: Longint;
  1210.     end;
  1211.  
  1212.   LPLineMediaControlDigit = ^TLineMediaControlDigit;
  1213.   TLineMediaControlDigit = record
  1214.     dwDigit,
  1215.     dwDigitModes,
  1216.     dwMediaControl: Longint;
  1217.     end;
  1218.  
  1219.   LPLineMediaControlMedia = ^TLineMediaControlMedia;
  1220.   TLineMediaControlMedia = record
  1221.     dwMediaModes,
  1222.     dwDuration,
  1223.     dwMediaControl: Longint;
  1224.     end;
  1225.  
  1226.   LPLineMediaControlTone = ^TLineMediaControlTone;
  1227.   TLineMediaControlTone = record
  1228.     dwAppSpecific,
  1229.     dwDuration,
  1230.     dwFrequency1,
  1231.     dwFrequency2,
  1232.     dwFrequency3,
  1233.     dwMediaControl: Longint;
  1234.     end;
  1235.  
  1236. const
  1237.   LINEMEDIACONTROL_NONE         = $00000001;
  1238.   LINEMEDIACONTROL_START        = $00000002;
  1239.   LINEMEDIACONTROL_RESET        = $00000004;
  1240.   LINEMEDIACONTROL_PAUSE        = $00000008;
  1241.   LINEMEDIACONTROL_RESUME       = $00000010;
  1242.   LINEMEDIACONTROL_RATEUP       = $00000020;
  1243.   LINEMEDIACONTROL_RATEDOWN     = $00000040;
  1244.   LINEMEDIACONTROL_RATENORMAL   = $00000080;
  1245.   LINEMEDIACONTROL_VOLUMEUP     = $00000100;
  1246.   LINEMEDIACONTROL_VOLUMEDOWN   = $00000200;
  1247.   LINEMEDIACONTROL_VOLUMENORMAL = $00000400;
  1248.  
  1249.   LINEMEDIAMODE_UNKNOWN           = $00000002;
  1250.   LINEMEDIAMODE_INTERACTIVEVOICE  = $00000004;
  1251.   LINEMEDIAMODE_AUTOMATEDVOICE    = $00000008;
  1252.   LINEMEDIAMODE_DATAMODEM         = $00000010;
  1253.   LINEMEDIAMODE_G3FAX             = $00000020;
  1254.   LINEMEDIAMODE_TDD               = $00000040;
  1255.   LINEMEDIAMODE_G4FAX             = $00000080;
  1256.   LINEMEDIAMODE_DIGITALDATA       = $00000100;
  1257.   LINEMEDIAMODE_TELETEX           = $00000200;
  1258.   LINEMEDIAMODE_VIDEOTEX          = $00000400;
  1259.   LINEMEDIAMODE_TELEX             = $00000800;
  1260.   LINEMEDIAMODE_MIXED             = $00001000;
  1261.   LINEMEDIAMODE_ADSI              = $00002000;
  1262.   LINEMEDIAMODE_VOICEVIEW         = $00004000;
  1263.  
  1264.   LAST_LINEMEDIAMODE  = $00004000;
  1265.  
  1266. type
  1267.   LPLineMonitorTone = ^TLineMonitorTone;
  1268.   TLineMonitorTone = record
  1269.     dwAppSpecific,
  1270.     dwDuration,
  1271.     dwFrequency1,
  1272.     dwFrequency2,
  1273.     dwFrequency3: Longint;
  1274.     end;
  1275.  
  1276. const
  1277.   LINEPARKMODE_DIRECTED     = $00000001;
  1278.   LINEPARKMODE_NONDIRECTED  = $00000002;
  1279.  
  1280.   LINEREMOVEFROMCONF_NONE = $00000001;
  1281.   LINEREMOVEFROMCONF_LAST = $00000002;
  1282.   LINEREMOVEFROMCONF_ANY  = $00000003;
  1283.  
  1284. type
  1285.   LPLineReqMakeCall = ^TLineReqMakeCall;
  1286.   TLineReqMakeCall = record
  1287.     szDestAddress: array[0.. TAPIMAXDESTADDRESSSIZE - 1] of char;
  1288.     szAppName: array[0..TAPIMAXAPPNAMESIZE - 1] of char;
  1289.     szCalledParty: array[0..TAPIMAXCALLEDPARTYSIZE - 1] of char;
  1290.     szComment: array[0..TAPIMAXCOMMENTSIZE] of char;
  1291.     end;
  1292.  
  1293.   LPLineReqMediaCall = ^TLineReqMediaCall;
  1294.   TLineReqMediaCall = record
  1295.     hWnd: HWnd;
  1296.     wRequestID: Word;
  1297.     szDeviceClass: array[0..TAPIMAXDEVICECLASSSIZE - 1] of char;
  1298.     ucDeviceID: array[0..TAPIMAXDEVICEIDSIZE] of Byte;
  1299.     dwSize,
  1300.     dwSecure: Longint;
  1301.     szDestAddress: array[0..TAPIMAXDESTADDRESSSIZE - 1] of char;
  1302.     szAppName: array[0..TAPIMAXAPPNAMESIZE - 1] of char;
  1303.     szCalledParty: array[0..TAPIMAXCALLEDPARTYSIZE - 1] of char;
  1304.     szComment: array[0..TAPIMAXCOMMENTSIZE - 1] of char;
  1305.     end;
  1306.  
  1307. const
  1308.   LINEREQUESTMODE_MAKECALL  = $00000001;
  1309.   LINEREQUESTMODE_MEDIACALL = $00000002;
  1310.   LINEREQUESTMODE_DROP      = $00000004;
  1311.  
  1312.   LAST_LINEREQUESTMODE  = LINEREQUESTMODE_MEDIACALL;
  1313.  
  1314.  
  1315.   LINEROAMMODE_UNKNOWN  = $00000001;
  1316.   LINEROAMMODE_UNAVAIL  = $00000002;
  1317.   LINEROAMMODE_HOME     = $00000004;
  1318.   LINEROAMMODE_ROAMA    = $00000008;
  1319.   LINEROAMMODE_ROAMB    = $00000010;
  1320.  
  1321.   LINESPECIALINFO_NOCIRCUIT = $00000001;
  1322.   LINESPECIALINFO_CUSTIRREG = $00000002;
  1323.   LINESPECIALINFO_REORDER   = $00000004;
  1324.   LINESPECIALINFO_UNKNOWN   = $00000008;
  1325.   LINESPECIALINFO_UNAVAIL   = $00000010;
  1326.  
  1327. type
  1328.   LPLineTermCaps = ^TLineTermCaps;
  1329.   TLineTermCaps = record
  1330.     dwTermDev,
  1331.     dwTermModes,
  1332.     dwTermSharing: Longint;
  1333.     end;
  1334.  
  1335. const
  1336.   LINETERMDEV_PHONE   = $00000001;
  1337.   LINETERMDEV_HEADSET = $00000002;
  1338.   LINETERMDEV_SPEAKER = $00000004;
  1339.  
  1340.   LINETERMMODE_BUTTONS       = $00000001;
  1341.   LINETERMMODE_LAMPS         = $00000002;
  1342.   LINETERMMODE_DISPLAY       = $00000004;
  1343.   LINETERMMODE_RINGER        = $00000008;
  1344.   LINETERMMODE_HOOKSWITCH    = $00000010;
  1345.   LINETERMMODE_MEDIATOLINE   = $00000020;
  1346.   LINETERMMODE_MEDIAFROMLINE = $00000040;
  1347.   LINETERMMODE_MEDIABIDIRECT = $00000080;
  1348.  
  1349.   LINETERMSHARING_PRIVATE     = $00000001;
  1350.   LINETERMSHARING_SHAREDEXCL  = $00000002;
  1351.   LINETERMSHARING_SHAREDCONF  = $00000004;
  1352.  
  1353.   LINETONEMODE_CUSTOM   = $00000001;
  1354.   LINETONEMODE_RINGBACK = $00000002;
  1355.   LINETONEMODE_BUSY     = $00000004;
  1356.   LINETONEMODE_BEEP     = $00000008;
  1357.   LINETONEMODE_BILLING  = $00000010;
  1358.  
  1359.   LINETRANSFERMODE_TRANSFER   = $00000001;
  1360.   LINETRANSFERMODE_CONFERENCE = $00000002;
  1361.  
  1362. type
  1363.   LPLineTranslateOutput = ^TLineTranslateOutput;
  1364.   TLineTranslateOutput = record
  1365.     dwTotalSize,
  1366.     dwNeededSize,
  1367.     dwUsedSize,
  1368.  
  1369.     dwDialableStringSize,
  1370.     dwDialableStringOffset,
  1371.     dwDisplayableStringSize,
  1372.     dwDisplayableStringOffset,
  1373.  
  1374.     dwCurrentCountry,
  1375.     dwDestCountry,
  1376.     dwTranslateResults: Longint;
  1377.     end;
  1378.  
  1379.   LPLineTranslateCaps = ^TLineTranslateCaps;
  1380.   TLineTranslateCaps = record
  1381.     dwTotalSize,
  1382.     dwNeededSize,
  1383.     dwUsedSize,
  1384.  
  1385.     dwNumLocations,
  1386.     dwLocationListSize,
  1387.     dwLocationListOffset,
  1388.  
  1389.     dwCurrentLocationID,
  1390.  
  1391.     dwNumCards,
  1392.     dwCardListSize,
  1393.     dwCardListOffset,
  1394.  
  1395.     dwCurrentPreferredCardID: Longint;
  1396.     end;
  1397.  
  1398.   LPLineLocationEntry = ^TLineLocationEntry;
  1399.   TLineLocationEntry = record
  1400.     dwPermanentLocationID,
  1401.     dwLocationNameSize,
  1402.     dwLocationNameOffset,
  1403.     dwCountryCode,
  1404.     dwCityCodeSize,
  1405.     dwCityCodeOffset,
  1406.     dwPreferredCardID,
  1407.     dwLocalAccessCodeSize,
  1408.     dwLocalAccessCodeOffset,
  1409.     dwLongDistanceAccessCodeSize,
  1410.     dwLongDistanceAccessCodeOffset,
  1411.     dwTollPrefixListSize,
  1412.     dwTollPrefixListOffset,
  1413.     dwCountryID,
  1414.     dwOptions,
  1415.     dwCancelCallWaitingSize,
  1416.     dwCancelCallWaitingOffset: Longint;
  1417.     end;
  1418.  
  1419.   LPLineCardEntry = ^TLineCardEntry;
  1420.   TLineCardEntry = record
  1421.     dwPermanentCardID,
  1422.     dwCardNameSize,
  1423.     dwCardNameOffset,
  1424.     dwCardNumberDigits,
  1425.     dwSameAreaRuleSize,
  1426.     dwSameAreaRuleOffset,
  1427.     dwLongDistanceRuleSize,
  1428.     dwLongDistanceRuleOffset,
  1429.     dwInternationalRuleSize,
  1430.     dwInternationalRuleOffset,
  1431.     dwOptions: Longint;
  1432.     end;
  1433.  
  1434.   LPLineCountryList = ^TLineCountryList;
  1435.   TLineCountryList = record
  1436.     dwTotalSize,
  1437.     dwNeededSize,
  1438.     dwUsedSize,
  1439.  
  1440.     dwNumCountries,
  1441.     dwCountryListSize,
  1442.     dwCountryListOffset: Longint;
  1443.     end;
  1444.  
  1445.   LPLineCountryEntry = ^TLineCountryEntry;
  1446.   TLineCountryEntry = record
  1447.     dwCountryID,
  1448.     dwCountryCode,
  1449.     dwNextCountryID,
  1450.     dwCountryNameSize,
  1451.     dwCountryNameOffset,
  1452.     dwSameAreaRuleSize,
  1453.     dwSameAreaRuleOffset,
  1454.     dwLongDistanceRuleSize,
  1455.     dwLongDistanceRuleOffset,
  1456.     dwInternationalRuleSize,
  1457.     dwInternationalRuleOffset: Longint;
  1458.     end;
  1459.  
  1460.   LPLineProviderList = ^TLineProviderList;
  1461.   TLineProviderList = record
  1462.     dwTotalSize,
  1463.     dwNeededSize,
  1464.     dwUsedSize,
  1465.     dwNumProviders,
  1466.     dwProviderListSize,
  1467.     dwProviderListOffset: Longint;
  1468.     end;
  1469.  
  1470.   LPLineProviderEntry = ^TLineProviderEntry;
  1471.   TLineProviderEntry = record
  1472.     dwPermanentProviderID,
  1473.     dwProviderFilenameSize,
  1474.     dwProviderFilenameOffset: Longint;
  1475.     end;
  1476.  
  1477. const
  1478.   LINETOLLLISTOPTION_ADD    = $00000001;
  1479.   LINETOLLLISTOPTION_REMOVE = $00000002;
  1480.  
  1481.   LINETRANSLATEOPTION_CARDOVERRIDE      = $00000001;
  1482.   LINETRANSLATEOPTION_CANCELCALLWAITING = $00000002;
  1483.   LINETRANSLATEOPTION_FORCELOCAL        = $00000004;
  1484.   LINETRANSLATEOPTION_FORCELD           = $00000008;
  1485.  
  1486.   LINETRANSLATERESULT_CANONICAL     = $00000001;
  1487.   LINETRANSLATERESULT_INTERNATIONAL = $00000002;
  1488.   LINETRANSLATERESULT_LONGDISTANCE  = $00000004;
  1489.   LINETRANSLATERESULT_LOCAL         = $00000008;
  1490.   LINETRANSLATERESULT_INTOLLLIST    = $00000010;
  1491.   LINETRANSLATERESULT_NOTINTOLLLIST = $00000020;
  1492.   LINETRANSLATERESULT_DIALBILLING   = $00000040;
  1493.   LINETRANSLATERESULT_DIALQUIET     = $00000080;
  1494.   LINETRANSLATERESULT_DIALDIALTONE  = $00000100;
  1495.   LINETRANSLATERESULT_DIALPROMPT    = $00000200;
  1496.  
  1497.  
  1498.   LINELOCATIONOPTION_PULSEDIAL  = $00000001;
  1499.  
  1500.   LINECARDOPTION_PREDEFINED = $00000001;
  1501.   LINECARDOPTION_HIDDEN     = $00000002;
  1502.  
  1503.  
  1504. { Simple Telephony prototypes }
  1505.  
  1506. {$IFDEF WIN32}
  1507.  
  1508. function tapiRequestMakeCall(
  1509.     lpszDestAddress, lpszAppName,
  1510.     lpszCalledParty, lpszComment: PChar): Longint; stdcall;
  1511.  
  1512. function tapiRequestMediaCall(
  1513.     Wnd: HWnd;
  1514.     wRequestID: Word;
  1515.     lpszDeviceClass, lpDeviceID: PChar;
  1516.     dwSize, dwSecure: Longint;
  1517.     lpszDestAddress, lpszAppName, lpszCalledParty, lpszComment: PChar): Longint; stdcall;
  1518.  
  1519. function tapiRequestDrop(
  1520.     Wnd: HWnd;
  1521.     wRequestID: Word): Longint; stdcall;
  1522.  
  1523. function lineRegisterRequestRecipient(
  1524.     hLineApp: THLineApp;
  1525.     dwRegistrationInstance, dwRequestMode, bEnable: Longint): Longint; stdcall;
  1526.  
  1527. function tapiGetLocationInfo(
  1528.     lpszCountryCode, lpszCityCode: PChar): Longint; stdcall;
  1529.  
  1530. { Tapi Address Translation procedures }
  1531. function lineSetCurrentLocation(
  1532.     hLineApp: THLineApp;
  1533.     dwLocation: Longint): Longint; stdcall;
  1534.  
  1535. function lineSetTollList(
  1536.     hLineApp: THLineApp;
  1537.     dwDeviceID: Longint;
  1538.     lpszAddressIn: PChar;
  1539.     dwTollListOption: Longint): Longint; stdcall;
  1540.  
  1541. function lineTranslateAddress(
  1542.     hLineApp: THLineApp;
  1543.     dwDeviceID, dwAPIVersion: Longint;
  1544.     lpszAddressIn: PChar;
  1545.     dwCard, dwTranslateOptions: Longint;
  1546.     var lpTranslateOutput: TLineTranslateOutput): Longint; stdcall;
  1547.  
  1548. function lineGetTranslateCaps(
  1549.     hLineApp: THLineApp;
  1550.     dwAPIVersion: Longint;
  1551.     var lpTranslateCaps: TLineTranslateCaps): Longint; stdcall;
  1552.  
  1553.  
  1554. { Tapi function prototypes }
  1555.  
  1556. function lineAccept(
  1557.     hCall: THCall;
  1558.     lpsUserUserInfo: PChar;
  1559.     dwSize: Longint): Longint; stdcall;
  1560.  
  1561. function lineAddToConference(
  1562.     hConfCall, hConsultCall: THCall): Longint; stdcall;
  1563.  
  1564. function lineAnswer(
  1565.     hCall: THCall;
  1566.     lpsUserUserInfo: PChar;
  1567.     dwSize: Longint): Longint; stdcall;
  1568.  
  1569. function lineBlindTransfer(
  1570.     hCall: THCall;
  1571.     lpszDestAddress: PChar;
  1572.     dwCountryCode: Longint): Longint; stdcall;
  1573.  
  1574. function lineClose(
  1575.     hLine: THLine): Longint; stdcall;
  1576.  
  1577. function  lineCompleteCall(
  1578.     hCall: THCall;
  1579.     var lpdwCompletionID: Longint;
  1580.     dwCompletionMode, dwMessageID: Longint): Longint; stdcall;
  1581.  
  1582. function lineCompleteTransfer(
  1583.     hCall, hConsultCall: THCall;
  1584.     var lphConfCall: THCall;
  1585.     dwTransferMode: Longint): Longint; stdcall;
  1586.  
  1587. function lineConfigDialog(
  1588.     dwDeviceID: Longint;
  1589.     hwndOwner: HWnd;
  1590.     lpszDeviceClass: PChar): Longint; stdcall;
  1591.  
  1592. function lineConfigDialogEdit(
  1593.     dwDeviceID: Longint;
  1594.     hwndOwner: HWnd;
  1595.     lpszDeviceClass: PChar;
  1596.     lpDeviceConfigIn: Pointer;
  1597.     dwSize: Longint;
  1598.     var lpDeviceConfigOut: TVarString): Longint; stdcall;
  1599.  
  1600. function lineDeallocateCall(
  1601.     hCall: THCall): Longint; stdcall;
  1602.  
  1603. function lineDevSpecific(
  1604.     hLine: THLine;
  1605.     dwAddressID: Longint;
  1606.     hCall: THCall;
  1607.     lpParams: Pointer;
  1608.     dwSize: Longint): Longint; stdcall;
  1609.  
  1610. function lineDevSpecificFeature(
  1611.     hLine: THLine;
  1612.     dwFeature: Longint;
  1613.     lpParams: Pointer;
  1614.     dwSize: Longint): Longint; stdcall;
  1615.  
  1616. function lineDial(
  1617.     hCall: THCall;
  1618.     lpszDestAddress: PChar;
  1619.     dwCountryCode: Longint): Longint; stdcall;
  1620.  
  1621. function lineDrop(
  1622.     hCall: THCall;
  1623.     lpsUserUserInfo: PChar;
  1624.     dwSize: Longint): Longint; stdcall;
  1625.  
  1626. function lineForward(
  1627.     hLine: THLine;
  1628.     bAllAddresses, dwAddressID: Longint;
  1629.     var lpForwardList: TLineForwardList;
  1630.     dwNumRingsNoAnswer: Longint;
  1631.     var lphConsultCall: THCall;
  1632.     var lpCallParams: TLineCallParams): Longint; stdcall;
  1633.  
  1634. function lineGatherDigits(
  1635.     hCall: THCall;
  1636.     dwDigitModes: Longint;
  1637.     lpsDigits: PChar;
  1638.     dwNumDigits: Longint;
  1639.     lpszTerminationDigits: PChar;
  1640.     dwFirstDigitTimeout, dwInterDigitTimeout: Longint): Longint; stdcall;
  1641.  
  1642. function lineGenerateDigits(
  1643.     hCall: THCall;
  1644.     dwDigitMode: Longint;
  1645.     lpszDigits: PChar;
  1646.     dwDuration: Longint): Longint; stdcall;
  1647.  
  1648. function lineGenerateTone(
  1649.     hCall: THCall;
  1650.     dwToneMode, dwDuration, dwNumTones: Longint;
  1651.     var lpTones: TLineGenerateTone): Longint; stdcall;
  1652.  
  1653. function lineGetAddressCaps(
  1654.     hLineApp: THLineApp;
  1655.     dwDeviceID, dwAddressID, dwAPIVersion, dwExtVersion: Longint;
  1656.     var lpAddressCaps: TLineAddressCaps): Longint; stdcall;
  1657.  
  1658. function lineGetAddressID(
  1659.     hLine: THLine;
  1660.     var lpdwAddressID: Longint;
  1661.     dwAddressMode: Longint;
  1662.     lpsAddress: Pchar;
  1663.     dwSize: Longint): Longint; stdcall;
  1664.  
  1665. function lineGetAddressStatus(
  1666.     hLine: THLine;
  1667.     dwAddressID: Longint;
  1668.     var lpAddressStatus: TLineAddressStatus): Longint; stdcall;
  1669.  
  1670. function lineGetCallInfo(
  1671.     hCall: THCall;
  1672.     var lpCallInfo: TLineCallInfo): Longint; stdcall;
  1673.  
  1674. function lineGetCallStatus(
  1675.     hCall: THCall;
  1676.     var lpCallStatus: TLineCallStatus): Longint; stdcall;
  1677.  
  1678. function lineGetConfRelatedCalls(
  1679.     hCall: THCall;
  1680.     var lpCallList: TLineCallList): Longint; stdcall;
  1681.  
  1682. function lineGetDevCaps(
  1683.     hLineApp: THLineApp;
  1684.     dwDeviceID, dwAPIVersion, dwExtVersion: Longint;
  1685.     var lpLineDevCaps: TLineDevCaps): Longint; stdcall;
  1686.  
  1687. function lineGetDevConfig(
  1688.     dwDeviceID: Longint;
  1689.     var lpDeviceConfig: TVarString;
  1690.     lpszDeviceClass: PChar): Longint; stdcall;
  1691.  
  1692. function lineGetNewCalls(
  1693.     hLine: THLine;
  1694.     dwAddressID, dwSelect: Longint;
  1695.     var lpCallList: TLineCallList): Longint; stdcall;
  1696.  
  1697. function lineGetIcon(
  1698.     dwDeviceID: Longint;
  1699.     lpszDeviceClass: PChar;
  1700.     var lphIcon: HIcon): Longint; stdcall;
  1701.  
  1702. function lineGetID(
  1703.     hLine: THLine;
  1704.     dwAddressID: Longint;
  1705.     hCall: THCall;
  1706.     dwSelect: Longint;
  1707.     var lpDeviceID: TVarString;
  1708.     lpszDeviceClass: PChar): Longint; stdcall;
  1709.  
  1710. function lineGetLineDevStatus(
  1711.     hLine: THLine;
  1712.     var lpLineDevStatus: TLineDevStatus): Longint; stdcall;
  1713.  
  1714. function lineGetNumRings(
  1715.     hLine: THLine;
  1716.     dwAddressID: Longint;
  1717.     var lpdwNumRings: Longint): Longint; stdcall;
  1718.  
  1719. function lineGetRequest(
  1720.     hLineApp: THLineApp;
  1721.     dwRequestMode: Longint;
  1722.     lpRequestBuffer: Pointer): Longint; stdcall;
  1723.  
  1724. function lineGetStatusMessages(
  1725.     hLine: THLine;
  1726.     var lpdwLineStates, lpdwAddressStates: Longint): Longint; stdcall;
  1727.  
  1728. function lineHandoff(
  1729.     hCall: THCall;
  1730.     lpszFileName: PChar;
  1731.     dwMediaMode: Longint): Longint; stdcall;
  1732.  
  1733. function lineHold(
  1734.     hCall: THCall): Longint; stdcall;
  1735.  
  1736. function lineInitialize(
  1737.     var lphLineApp: THLineApp;
  1738.     hInstance: THandle;
  1739.     lpfnCallback: Pointer;
  1740.     lpszAppName: PChar;
  1741.     var lpdwNumDevs: Longint): Longint; stdcall;
  1742.  
  1743. function lineMakeCall(
  1744.     hLine: THLine;
  1745.     var lphCall: THCall;
  1746.     lpszDestAddress: Pchar;
  1747.     dwCountryCode: Longint;
  1748.     var lpCallParams: TLineCallparams): Longint; stdcall;
  1749.  
  1750. function lineMonitorDigits(
  1751.     hCall: THCall;
  1752.     dwDigitModes: Longint): Longint; stdcall;
  1753.  
  1754. function lineMonitorMedia(
  1755.     hCall: THCall;
  1756.     dwMediaModes: Longint): Longint; stdcall;
  1757.  
  1758. function lineMonitorTones(
  1759.     hCall: THCall;
  1760.     var lpToneList: TLineMonitorTone;
  1761.     dwNumEntries: Longint): Longint; stdcall;
  1762.  
  1763. function lineNegotiateAPIVersion(
  1764.     hLineApp: THLineApp;
  1765.     dwDeviceID, dwAPILowVersion, dwAPIHighVersion: Longint;
  1766.     var lpdwAPIVersion: Longint;
  1767.     var lpExtensionID: TLineExtensionID): Longint; stdcall;
  1768.  
  1769. function lineNegotiateExtVersion(
  1770.     hLineApp: THLineApp;
  1771.     dwDeviceID, dwAPIVersion, dwExtLowVersion, dwExtHighVersion: Longint;
  1772.     var lpdwExtVersion: Longint): Longint; stdcall;
  1773.  
  1774. function lineOpen(
  1775.     hLineApp: THLineApp;
  1776.     dwDeviceID: Longint;
  1777.     var lphLine: THLine;
  1778.     dwAPIVersion, dwExtVersion, dwCallbackInstance,
  1779.     dwPrivileges, dwMediaModes: Longint;
  1780.     var lpCallParams: TLineCallParams): Longint; stdcall;
  1781.  
  1782. function linePark(
  1783.     hCall: THCall;
  1784.     dwParkMode: Longint;
  1785.     lpszDirAddress: PChar;
  1786.     var lpNonDirAddress: TVarString): Longint; stdcall;
  1787.  
  1788. function linePickup(
  1789.     hLine: THLine;
  1790.     dwAddressID: Longint;
  1791.     var lphCall: THCall;
  1792.     lpszDestAddress, lpszGroupID: PChar): Longint; stdcall;
  1793.  
  1794. function linePrepareAddToConference(
  1795.     hConfCall: THCall;
  1796.     var lphConsultCall: THCall;
  1797.     var lpCallParams: TLineCallParams): Longint; stdcall;
  1798.  
  1799. function lineRedirect(
  1800.     hCall: THCall;
  1801.     lpszDestAddress: PChar;
  1802.     dwCountryCode: Longint): Longint; stdcall;
  1803.  
  1804. function lineRemoveFromConference(
  1805.     hCall: THCall): Longint; stdcall;
  1806.  
  1807. function lineSecureCall(
  1808.     hCall: THCall): Longint; stdcall;
  1809.  
  1810. function lineSendUserUserInfo(
  1811.     hCall: THCall;
  1812.     lpsUserUserInfo: PChar;
  1813.     dwSize: Longint): Longint; stdcall;
  1814.  
  1815. function lineSetAppSpecific(
  1816.     hCall: THCall;
  1817.     dwAppSpecific: Longint): Longint; stdcall;
  1818.  
  1819. function lineSetCallParams(
  1820.     hCall: THCall;
  1821.     dwBearerMode, dwMinRate, dwMaxRate: Longint;
  1822.     var lpDialParams: TLineDialParams): Longint; stdcall;
  1823.  
  1824. function lineSetCallPrivilege(
  1825.     hCall: THCall;
  1826.     dwCallPrivilege: Longint): Longint; stdcall;
  1827.  
  1828. function lineSetDevConfig(
  1829.     dwDeviceID: Longint;
  1830.     lpDeviceConfig: Pointer;
  1831.     dwSize: Longint;
  1832.     lpszDeviceClass: PChar): Longint; stdcall;
  1833.  
  1834. function lineSetMediaControl(
  1835.     hLine: THLine;
  1836.     dwAddressID: Longint;
  1837.     hCall: THCall;
  1838.     dwSelect: Longint;
  1839.     var lpDigitList: TLineMediaControlDigit;
  1840.     dwDigitNumEntries: Longint;
  1841.     var lpMediaList: TLineMediaControlMedia;
  1842.     dwMediaNumEntries: Longint;
  1843.     var lpToneList: TLineMediaControlTone;
  1844.     dwToneNumEntries: Longint;
  1845.     var lpCallStateList: TLineMediaControlCallState;
  1846.     dwCallStateNumEntries: Longint): Longint; stdcall;
  1847.  
  1848. function lineSetMediaMode(
  1849.     hCall: THCall;
  1850.     dwMediaModes: Longint): Longint; stdcall;
  1851.  
  1852. function lineSetNumRings(
  1853.     hLine: THLine;
  1854.     dwAddressID, dwNumRings: Longint): Longint; stdcall;
  1855.  
  1856. function lineSetStatusMessages(
  1857.     hLine: THLine;
  1858.     dwLineStates, dwAddressStates: Longint): Longint; stdcall;
  1859.  
  1860. function lineSetTerminal(
  1861.     hLine: THLine;
  1862.     dwAddressID: Longint;
  1863.     hCall: THCall;
  1864.     dwSelect, dwTerminalModes, dwTerminalID, bEnable: Longint): Longint; stdcall;
  1865.  
  1866. function lineSetupConference(
  1867.     hCall: THCall;
  1868.     hLine: THLine;
  1869.     varlphConfCall, lphConsultCall: THCall;
  1870.     dwNumParties: Longint;
  1871.     var lpCallParams: TLineCallParams): Longint; stdcall;
  1872.  
  1873. function lineSetupTransfer(
  1874.     hCall: THCall;
  1875.     var lphConsultCall: THCall;
  1876.     var lpCallParams: TLineCallParams): Longint; stdcall;
  1877.  
  1878. function lineShutdown(
  1879.     hLineApp: THLineApp): Longint; stdcall;
  1880.  
  1881. function lineSwapHold(
  1882.     hActiveCall, hHeldCall: THCall): Longint; stdcall;
  1883.  
  1884. function lineUncompleteCall(
  1885.     hLine: THLine;
  1886.     dwCompletionID: Longint): Longint; stdcall;
  1887.  
  1888. function lineUnhold(
  1889.     hCall: THCall): Longint; stdcall;
  1890.  
  1891. function lineUnpark(
  1892.     hLine: THLine;
  1893.     dwAddressID: Longint;
  1894.     var lphCall: THCall;
  1895.     lpszDestAddress: PChar): Longint; stdcall;
  1896.  
  1897. function lineReleaseUserUserInfo(
  1898.     hCall: THCall): Longint; stdcall;
  1899.  
  1900.  
  1901. function phoneClose(
  1902.     hPhone: THPhone): Longint; stdcall;
  1903.  
  1904. function phoneConfigDialog(
  1905.     dwDeviceID: Longint;
  1906.     hwndOwner: HWnd;
  1907.     lpszDeviceClass: PChar): Longint; stdcall;
  1908.  
  1909. function phoneDevSpecific(
  1910.     hPhone: THPhone;
  1911.     lpParams: Pointer;
  1912.     dwSize: Longint): Longint; stdcall;
  1913.  
  1914. function phoneGetButtonInfo(
  1915.     hPhone: THPhone;
  1916.     dwButtonLampID: Longint;
  1917.     var lpButtonInfo: TPhoneButtonInfo): Longint; stdcall;
  1918.  
  1919. function phoneGetData(
  1920.     hPhone: THPhone;
  1921.     dwDataID: Longint;
  1922.     lpData: Pointer;
  1923.     dwSize: Longint): Longint; stdcall;
  1924.  
  1925. function phoneGetDevCaps(
  1926.     hPhoneApp: THPhoneApp;
  1927.     dwDeviceID, dwAPIVersion, dwExtVersion: Longint;
  1928.     var lpPhoneCaps: TPhoneCaps): Longint; stdcall;
  1929.  
  1930. function phoneGetDisplay(
  1931.     hPhone: THPhone;
  1932.     var lpDisplay: TVarString): Longint; stdcall;
  1933.  
  1934. function phoneGetGain(
  1935.     hPhone: THPhone;
  1936.     dwHookSwitchDev: Longint;
  1937.     var lpdwGain: Longint): Longint; stdcall;
  1938.  
  1939. function phoneGetHookSwitch(
  1940.     hPhone: THPhone;
  1941.     var lpdwHookSwitchDevs: Longint): Longint; stdcall;
  1942.  
  1943. function phoneGetIcon(
  1944.     dwDeviceID: Longint;
  1945.     lpszDeviceClass: PChar;
  1946.     var lphIcon: HIcon): Longint; stdcall;
  1947.  
  1948. function phoneGetID(
  1949.     hPhone: THPhone;
  1950.     var lpDeviceID: TVarString;
  1951.     lpszDeviceClass: PChar): Longint; stdcall;
  1952.  
  1953. function phoneGetLamp(
  1954.     hPhone: THPhone;
  1955.     dwButtonLampID: Longint;
  1956.     var lpdwLampMode: Longint): Longint; stdcall;
  1957.  
  1958. function phoneGetRing(
  1959.     hPhone: THPhone;
  1960.     var lpdwRingMode, lpdwVolume: Longint): Longint; stdcall;
  1961.  
  1962. function phoneGetStatus(
  1963.     hPhone: THPhone;
  1964.     var lpPhoneStatus: TPhoneStatus): Longint; stdcall;
  1965.  
  1966. function phoneGetStatusMessages(
  1967.     hPhone: THPhone;
  1968.     var lpdwPhoneStates, lpdwButtonModes, lpdwButtonStates: Longint): Longint; stdcall;
  1969.  
  1970. function phoneGetVolume(
  1971.     hPhone: THPhone;
  1972.     dwHookSwitchDev: Longint;
  1973.     var lpdwVolume: Longint): Longint; stdcall;
  1974.  
  1975. function phoneInitialize(
  1976.     var lphPhoneApp: THPhoneApp;
  1977.     hInstance: THandle;
  1978.     lpfnCallback: Pointer;
  1979.     lpszAppName: PChar;
  1980.     var lpdwNumDevs: Longint): Longint; stdcall;
  1981.  
  1982. function phoneNegotiateAPIVersion(
  1983.     hPhoneApp: THPhoneApp;
  1984.     dwDeviceID, dwAPILowVersion, dwAPIHighVersion: Longint;
  1985.     var lpdwAPIVersion: Longint;
  1986.     var lpExtensionID: TPHoneExtensionID): Longint; stdcall;
  1987.  
  1988. function phoneNegotiateExtVersion(
  1989.     hPhoneApp: THPhoneApp;
  1990.     dwDeviceID, dwAPIVersion, dwExtLowVersion, dwExtHighVersion: Longint;
  1991.     var lpdwExtVersion: Longint): Longint; stdcall;
  1992.  
  1993. function phoneOpen(
  1994.     hPhoneApp: THPhoneApp;
  1995.     dwDeviceID: Longint;
  1996.     var lphPhone: THPhone;
  1997.     dwAPIVersion, dwExtVersion, dwCallbackInstance, dwPrivilege: Longint): Longint; stdcall;
  1998.  
  1999. function phoneSetButtonInfo(
  2000.     hPhone: THPhone;
  2001.     dwButtonLampID: Longint;
  2002.     var lpButtonInfo: TPhoneButtonInfo): Longint; stdcall;
  2003.  
  2004. function phoneSetData(
  2005.     hPhone: THPhone;
  2006.     dwDataID: Longint;
  2007.     lpData: Pointer;
  2008.     dwSize: Longint): Longint; stdcall;
  2009.  
  2010. function phoneSetDisplay(
  2011.     hPhone: THPhone;
  2012.     dwRow, dwColumn: Longint;
  2013.     lpsDisplay: PChar;
  2014.     dwSize: Longint): Longint; stdcall;
  2015.  
  2016. function phoneSetGain(
  2017.     hPhone: THPhone;
  2018.     dwHookSwitchDev, dwGain: Longint): Longint; stdcall;
  2019.  
  2020. function phoneSetHookSwitch(
  2021.     hPhone: THPhone;
  2022.     dwHookSwitchDevs, dwHookSwitchMode: Longint): Longint; stdcall;
  2023.  
  2024. function phoneSetLamp(
  2025.     hPhone: THPhone;
  2026.     dwButtonLampID, dwLampMode: Longint): Longint; stdcall;
  2027.  
  2028. function phoneSetRing(
  2029.     hPhone: THPhone;
  2030.     dwRingMode, dwVolume: Longint): Longint; stdcall;
  2031.  
  2032. function phoneSetStatusMessages(
  2033.     hPhone: THPhone;
  2034.     dwPhoneStates, dwButtonModes, dwButtonStates: Longint): Longint; stdcall;
  2035.  
  2036. function phoneSetVolume(
  2037.     hPhone: THPhone;
  2038.     dwHookSwitchDev, dwVolume: Longint): Longint; stdcall;
  2039.  
  2040. function phoneShutdown(hPhoneApp: THPhoneApp): Longint; stdcall;
  2041.  
  2042.  
  2043. function lineTranslateDialog(
  2044.     hLineApp: THLineApp;
  2045.     dwDeviceID, dwAPIVersion: Longint;
  2046.     hwndOwner: HWnd;
  2047.     lpszAddressIn: PChar): Longint; stdcall;
  2048.  
  2049. function lineGetCountry(
  2050.     dwCountryID, dwAPIVersion: Longint;
  2051.     var lpLineCountryList: TLineCountryList): Longint; stdcall;
  2052.  
  2053. function lineGetAppPriority(
  2054.     lpszAppFilename: PChar;
  2055.     dwMediaMode: Longint;
  2056.     var lpExtensionID: TLineExtensionID;
  2057.     dwRequestMode: Longint;
  2058.     var lpExtensionName: TVarString;
  2059.     var lpdwPriority: Longint): Longint; stdcall;
  2060.  
  2061. function lineSetAppPriority(
  2062.     lpszAppFilename: PChar;
  2063.     dwMediaMode: Longint;
  2064.     var lpExtensionID: TLineExtensionID;
  2065.     dwRequestMode: Longint;
  2066.     lpszExtensionName: PChar;
  2067.     dwPriority: Longint): Longint; stdcall;
  2068.  
  2069. function lineAddProvider(
  2070.     lpszProviderFilename: PChar;
  2071.     hwndOwner: THandle;
  2072.     var lpdwPermanentProviderID: Longint): Longint; stdcall;
  2073.  
  2074. function lineConfigProvider(
  2075.     hwndOwner: THandle;
  2076.     dwPermanentProviderID: Longint): Longint; stdcall;
  2077.  
  2078. function lineRemoveProvider(
  2079.     dwPermanentProviderID: Longint;
  2080.     hwndOwner: THandle): Longint; stdcall;
  2081.  
  2082. function lineGetProviderList(
  2083.     dwAPIVersion: Longint;
  2084.     var lpProviderList: TLineProviderList): Longint; stdcall;
  2085.  
  2086. {$ELSE}
  2087.  
  2088. function tapiRequestMakeCall(
  2089.     lpszDestAddress, lpszAppName,
  2090.     lpszCalledParty, lpszComment: PChar): Longint;
  2091.  
  2092. function tapiRequestMediaCall(
  2093.     Wnd: HWnd;
  2094.     wRequestID: Word;
  2095.     lpszDeviceClass, lpDeviceID: PChar;
  2096.     dwSize, dwSecure: Longint;
  2097.     lpszDestAddress, lpszAppName, lpszCalledParty, lpszComment: PChar): Longint;
  2098.  
  2099. function tapiRequestDrop(
  2100.     Wnd: HWnd;
  2101.     wRequestID: Word): Longint;
  2102.  
  2103. function lineRegisterRequestRecipient(
  2104.     hLineApp: THLineApp;
  2105.     dwRegistrationInstance, dwRequestMode, bEnable: Longint): Longint;
  2106.  
  2107. function tapiGetLocationInfo(
  2108.     lpszCountryCode, lpszCityCode: PChar): Longint;
  2109.  
  2110. { Tapi Address Translation procedures }
  2111. function lineSetCurrentLocation(
  2112.     hLineApp: THLineApp;
  2113.     dwLocation: Longint): Longint;
  2114.  
  2115. function lineSetTollList(
  2116.     hLineApp: THLineApp;
  2117.     dwDeviceID: Longint;
  2118.     lpszAddressIn: PChar;
  2119.     dwTollListOption: Longint): Longint;
  2120.  
  2121. function lineTranslateAddress(
  2122.     hLineApp: THLineApp;
  2123.     dwDeviceID, dwAPIVersion: Longint;
  2124.     lpszAddressIn: PChar;
  2125.     dwCard, dwTranslateOptions: Longint;
  2126.     var lpTranslateOutput: TLineTranslateOutput): Longint;
  2127.  
  2128. function lineGetTranslateCaps(
  2129.     hLineApp: THLineApp;
  2130.     dwAPIVersion: Longint;
  2131.     var lpTranslateCaps: TLineTranslateCaps): Longint;
  2132.  
  2133.  
  2134. { Tapi function prototypes }
  2135.  
  2136. function lineAccept(
  2137.     hCall: THCall;
  2138.     lpsUserUserInfo: PChar;
  2139.     dwSize: Longint): Longint;
  2140.  
  2141. function lineAddToConference(
  2142.     hConfCall, hConsultCall: THCall): Longint;
  2143.  
  2144. function lineAnswer(
  2145.     hCall: THCall;
  2146.     lpsUserUserInfo: PChar;
  2147.     dwSize: Longint): Longint;
  2148.  
  2149. function lineBlindTransfer(
  2150.     hCall: THCall;
  2151.     lpszDestAddress: PChar;
  2152.     dwCountryCode: Longint): Longint;
  2153.  
  2154. function lineClose(
  2155.     hLine: THLine): Longint;
  2156.  
  2157. function  lineCompleteCall(
  2158.     hCall: THCall;
  2159.     var lpdwCompletionID: Longint;
  2160.     dwCompletionMode, dwMessageID: Longint): Longint;
  2161.  
  2162. function lineCompleteTransfer(
  2163.     hCall, hConsultCall: THCall;
  2164.     var lphConfCall: THCall;
  2165.     dwTransferMode: Longint): Longint;
  2166.  
  2167. function lineConfigDialog(
  2168.     dwDeviceID: Longint;
  2169.     hwndOwner: HWnd;
  2170.     lpszDeviceClass: PChar): Longint;
  2171.  
  2172. function lineConfigDialogEdit(
  2173.     dwDeviceID: Longint;
  2174.     hwndOwner: HWnd;
  2175.     lpszDeviceClass: PChar;
  2176.     lpDeviceConfigIn: Pointer;
  2177.     dwSize: Longint;
  2178.     var lpDeviceConfigOut: TVarString): Longint;
  2179.  
  2180. function lineDeallocateCall(
  2181.     hCall: THCall): Longint;
  2182.  
  2183. function lineDevSpecific(
  2184.     hLine: THLine;
  2185.     dwAddressID: Longint;
  2186.     hCall: THCall;
  2187.     lpParams: Pointer;
  2188.     dwSize: Longint): Longint;
  2189.  
  2190. function lineDevSpecificFeature(
  2191.     hLine: THLine;
  2192.     dwFeature: Longint;
  2193.     lpParams: Pointer;
  2194.     dwSize: Longint): Longint;
  2195.  
  2196. function lineDial(
  2197.     hCall: THCall;
  2198.     lpszDestAddress: PChar;
  2199.     dwCountryCode: Longint): Longint;
  2200.  
  2201. function lineDrop(
  2202.     hCall: THCall;
  2203.     lpsUserUserInfo: PChar;
  2204.     dwSize: Longint): Longint;
  2205.  
  2206. function lineForward(
  2207.     hLine: THLine;
  2208.     bAllAddresses, dwAddressID: Longint;
  2209.     var lpForwardList: TLineForwardList;
  2210.     dwNumRingsNoAnswer: Longint;
  2211.     var lphConsultCall: THCall;
  2212.     var lpCallParams: TLineCallParams): Longint;
  2213.  
  2214. function lineGatherDigits(
  2215.     hCall: THCall;
  2216.     dwDigitModes: Longint;
  2217.     lpsDigits: PChar;
  2218.     dwNumDigits: Longint;
  2219.     lpszTerminationDigits: PChar;
  2220.     dwFirstDigitTimeout, dwInterDigitTimeout: Longint): Longint;
  2221.  
  2222. function lineGenerateDigits(
  2223.     hCall: THCall;
  2224.     dwDigitMode: Longint;
  2225.     lpszDigits: PChar;
  2226.     dwDuration: Longint): Longint;
  2227.  
  2228. function lineGenerateTone(
  2229.     hCall: THCall;
  2230.     dwToneMode, dwDuration, dwNumTones: Longint;
  2231.     var lpTones: TLineGenerateTone): Longint;
  2232.  
  2233. function lineGetAddressCaps(
  2234.     hLineApp: THLineApp;
  2235.     dwDeviceID, dwAddressID, dwAPIVersion, dwExtVersion: Longint;
  2236.     var lpAddressCaps: TLineAddressCaps): Longint;
  2237.  
  2238. function lineGetAddressID(
  2239.     hLine: THLine;
  2240.     var lpdwAddressID: Longint;
  2241.     dwAddressMode: Longint;
  2242.     lpsAddress: Pchar;
  2243.     dwSize: Longint): Longint;
  2244.  
  2245. function lineGetAddressStatus(
  2246.     hLine: THLine;
  2247.     dwAddressID: Longint;
  2248.     var lpAddressStatus: TLineAddressStatus): Longint;
  2249.  
  2250. function lineGetCallInfo(
  2251.     hCall: THCall;
  2252.     var lpCallInfo: TLineCallInfo): Longint;
  2253.  
  2254. function lineGetCallStatus(
  2255.     hCall: THCall;
  2256.     var lpCallStatus: TLineCallStatus): Longint;
  2257.  
  2258. function lineGetConfRelatedCalls(
  2259.     hCall: THCall;
  2260.     var lpCallList: TLineCallList): Longint;
  2261.  
  2262. function lineGetDevCaps(
  2263.     hLineApp: THLineApp;
  2264.     dwDeviceID, dwAPIVersion, dwExtVersion: Longint;
  2265.     var lpLineDevCaps: TLineDevCaps): Longint;
  2266.  
  2267. function lineGetDevConfig(
  2268.     dwDeviceID: Longint;
  2269.     var lpDeviceConfig: TVarString;
  2270.     lpszDeviceClass: PChar): Longint;
  2271.  
  2272. function lineGetNewCalls(
  2273.     hLine: THLine;
  2274.     dwAddressID, dwSelect: Longint;
  2275.     var lpCallList: TLineCallList): Longint;
  2276.  
  2277. function lineGetIcon(
  2278.     dwDeviceID: Longint;
  2279.     lpszDeviceClass: PChar;
  2280.     var lphIcon: HIcon): Longint;
  2281.  
  2282. function lineGetID(
  2283.     hLine: THLine;
  2284.     dwAddressID: Longint;
  2285.     hCall: THCall;
  2286.     dwSelect: Longint;
  2287.     var lpDeviceID: TVarString;
  2288.     lpszDeviceClass: PChar): Longint; 
  2289.  
  2290. function lineGetLineDevStatus(
  2291.     hLine: THLine;
  2292.     var lpLineDevStatus: TLineDevStatus): Longint;
  2293.  
  2294. function lineGetNumRings(
  2295.     hLine: THLine;
  2296.     dwAddressID: Longint;
  2297.     var lpdwNumRings: Longint): Longint;
  2298.  
  2299. function lineGetRequest(
  2300.     hLineApp: THLineApp;
  2301.     dwRequestMode: Longint;
  2302.     lpRequestBuffer: Pointer): Longint;
  2303.  
  2304. function lineGetStatusMessages(
  2305.     hLine: THLine;
  2306.     var lpdwLineStates, lpdwAddressStates: Longint): Longint;
  2307.  
  2308. function lineHandoff(
  2309.     hCall: THCall;
  2310.     lpszFileName: PChar;
  2311.     dwMediaMode: Longint): Longint; 
  2312.  
  2313. function lineHold(
  2314.     hCall: THCall): Longint; 
  2315.  
  2316. function lineInitialize(
  2317.     var lphLineApp: THLineApp;
  2318.     hInstance: THandle;
  2319.     lpfnCallback: Pointer;
  2320.     lpszAppName: PChar;
  2321.     var lpdwNumDevs: Longint): Longint;
  2322.  
  2323. function lineMakeCall(
  2324.     hLine: THLine;
  2325.     var lphCall: THCall;
  2326.     lpszDestAddress: Pchar;
  2327.     dwCountryCode: Longint;
  2328.     var lpCallParams: TLineCallparams): Longint; 
  2329.  
  2330. function lineMonitorDigits(
  2331.     hCall: THCall;
  2332.     dwDigitModes: Longint): Longint; 
  2333.  
  2334. function lineMonitorMedia(
  2335.     hCall: THCall;
  2336.     dwMediaModes: Longint): Longint;
  2337.  
  2338. function lineMonitorTones(
  2339.     hCall: THCall;
  2340.     var lpToneList: TLineMonitorTone;
  2341.     dwNumEntries: Longint): Longint; 
  2342.  
  2343. function lineNegotiateAPIVersion(
  2344.     hLineApp: THLineApp;
  2345.     dwDeviceID, dwAPILowVersion, dwAPIHighVersion: Longint;
  2346.     var lpdwAPIVersion: Longint;
  2347.     var lpExtensionID: TLineExtensionID): Longint; 
  2348.  
  2349. function lineNegotiateExtVersion(
  2350.     hLineApp: THLineApp;
  2351.     dwDeviceID, dwAPIVersion, dwExtLowVersion, dwExtHighVersion: Longint;
  2352.     var lpdwExtVersion: Longint): Longint; 
  2353.  
  2354. function lineOpen(
  2355.     hLineApp: THLineApp;
  2356.     dwDeviceID: Longint;
  2357.     var lphLine: THLine;
  2358.     dwAPIVersion, dwExtVersion, dwCallbackInstance,
  2359.     dwPrivileges, dwMediaModes: Longint;
  2360.     var lpCallParams: TLineCallParams): Longint; 
  2361.  
  2362. function linePark(
  2363.     hCall: THCall;
  2364.     dwParkMode: Longint;
  2365.     lpszDirAddress: PChar;
  2366.     var lpNonDirAddress: TVarString): Longint; 
  2367.  
  2368. function linePickup(
  2369.     hLine: THLine;
  2370.     dwAddressID: Longint;
  2371.     var lphCall: THCall;
  2372.     lpszDestAddress, lpszGroupID: PChar): Longint; 
  2373.  
  2374. function linePrepareAddToConference(
  2375.     hConfCall: THCall;
  2376.     var lphConsultCall: THCall;
  2377.     var lpCallParams: TLineCallParams): Longint; 
  2378.  
  2379. function lineRedirect(
  2380.     hCall: THCall;
  2381.     lpszDestAddress: PChar;
  2382.     dwCountryCode: Longint): Longint;
  2383.  
  2384. function lineRemoveFromConference(
  2385.     hCall: THCall): Longint;
  2386.  
  2387. function lineSecureCall(
  2388.     hCall: THCall): Longint;
  2389.  
  2390. function lineSendUserUserInfo(
  2391.     hCall: THCall;
  2392.     lpsUserUserInfo: PChar;
  2393.     dwSize: Longint): Longint;
  2394.  
  2395. function lineSetAppSpecific(
  2396.     hCall: THCall;
  2397.     dwAppSpecific: Longint): Longint;
  2398.  
  2399. function lineSetCallParams(
  2400.     hCall: THCall;
  2401.     dwBearerMode, dwMinRate, dwMaxRate: Longint;
  2402.     var lpDialParams: TLineDialParams): Longint;
  2403.  
  2404. function lineSetCallPrivilege(
  2405.     hCall: THCall;
  2406.     dwCallPrivilege: Longint): Longint;
  2407.  
  2408. function lineSetDevConfig(
  2409.     dwDeviceID: Longint;
  2410.     lpDeviceConfig: Pointer;
  2411.     dwSize: Longint;
  2412.     lpszDeviceClass: PChar): Longint;
  2413.  
  2414. function lineSetMediaControl(
  2415.     hLine: THLine;
  2416.     dwAddressID: Longint;
  2417.     hCall: THCall;
  2418.     dwSelect: Longint;
  2419.     var lpDigitList: TLineMediaControlDigit;
  2420.     dwDigitNumEntries: Longint;
  2421.     var lpMediaList: TLineMediaControlMedia;
  2422.     dwMediaNumEntries: Longint;
  2423.     var lpToneList: TLineMediaControlTone;
  2424.     dwToneNumEntries: Longint;
  2425.     var lpCallStateList: TLineMediaControlCallState;
  2426.     dwCallStateNumEntries: Longint): Longint;
  2427.  
  2428. function lineSetMediaMode(
  2429.     hCall: THCall;
  2430.     dwMediaModes: Longint): Longint;
  2431.  
  2432. function lineSetNumRings(
  2433.     hLine: THLine;
  2434.     dwAddressID, dwNumRings: Longint): Longint;
  2435.  
  2436. function lineSetStatusMessages(
  2437.     hLine: THLine;
  2438.     dwLineStates, dwAddressStates: Longint): Longint;
  2439.  
  2440. function lineSetTerminal(
  2441.     hLine: THLine;
  2442.     dwAddressID: Longint;
  2443.     hCall: THCall;
  2444.     dwSelect, dwTerminalModes, dwTerminalID, bEnable: Longint): Longint;
  2445.  
  2446. function lineSetupConference(
  2447.     hCall: THCall;
  2448.     hLine: THLine;
  2449.     varlphConfCall, lphConsultCall: THCall;
  2450.     dwNumParties: Longint;
  2451.     var lpCallParams: TLineCallParams): Longint;
  2452.  
  2453. function lineSetupTransfer(
  2454.     hCall: THCall;
  2455.     var lphConsultCall: THCall;
  2456.     var lpCallParams: TLineCallParams): Longint;
  2457.  
  2458. function lineShutdown(
  2459.     hLineApp: THLineApp): Longint;
  2460.  
  2461. function lineSwapHold(
  2462.     hActiveCall, hHeldCall: THCall): Longint;
  2463.  
  2464. function lineUncompleteCall(
  2465.     hLine: THLine;
  2466.     dwCompletionID: Longint): Longint;
  2467.  
  2468. function lineUnhold(
  2469.     hCall: THCall): Longint;
  2470.  
  2471. function lineUnpark(
  2472.     hLine: THLine;
  2473.     dwAddressID: Longint;
  2474.     var lphCall: THCall;
  2475.     lpszDestAddress: PChar): Longint;
  2476.  
  2477. function lineReleaseUserUserInfo(
  2478.     hCall: THCall): Longint;
  2479.  
  2480.  
  2481. function phoneClose(
  2482.     hPhone: THPhone): Longint;
  2483.  
  2484. function phoneConfigDialog(
  2485.     dwDeviceID: Longint;
  2486.     hwndOwner: HWnd;
  2487.     lpszDeviceClass: PChar): Longint;
  2488.  
  2489. function phoneDevSpecific(
  2490.     hPhone: THPhone;
  2491.     lpParams: Pointer;
  2492.     dwSize: Longint): Longint;
  2493.  
  2494. function phoneGetButtonInfo(
  2495.     hPhone: THPhone;
  2496.     dwButtonLampID: Longint;
  2497.     var lpButtonInfo: TPhoneButtonInfo): Longint;
  2498.  
  2499. function phoneGetData(
  2500.     hPhone: THPhone;
  2501.     dwDataID: Longint;
  2502.     lpData: Pointer;
  2503.     dwSize: Longint): Longint;
  2504.  
  2505. function phoneGetDevCaps(
  2506.     hPhoneApp: THPhoneApp;
  2507.     dwDeviceID, dwAPIVersion, dwExtVersion: Longint;
  2508.     var lpPhoneCaps: TPhoneCaps): Longint;
  2509.  
  2510. function phoneGetDisplay(
  2511.     hPhone: THPhone;
  2512.     var lpDisplay: TVarString): Longint;
  2513.  
  2514. function phoneGetGain(
  2515.     hPhone: THPhone;
  2516.     dwHookSwitchDev: Longint;
  2517.     var lpdwGain: Longint): Longint;
  2518.  
  2519. function phoneGetHookSwitch(
  2520.     hPhone: THPhone;
  2521.     var lpdwHookSwitchDevs: Longint): Longint;
  2522.  
  2523. function phoneGetIcon(
  2524.     dwDeviceID: Longint;
  2525.     lpszDeviceClass: PChar;
  2526.     var lphIcon: HIcon): Longint;
  2527.  
  2528. function phoneGetID(
  2529.     hPhone: THPhone;
  2530.     var lpDeviceID: TVarString;
  2531.     lpszDeviceClass: PChar): Longint;
  2532.  
  2533. function phoneGetLamp(
  2534.     hPhone: THPhone;
  2535.     dwButtonLampID: Longint;
  2536.     var lpdwLampMode: Longint): Longint;
  2537.  
  2538. function phoneGetRing(
  2539.     hPhone: THPhone;
  2540.     var lpdwRingMode, lpdwVolume: Longint): Longint;
  2541.  
  2542. function phoneGetStatus(
  2543.     hPhone: THPhone;
  2544.     var lpPhoneStatus: TPhoneStatus): Longint;
  2545.  
  2546. function phoneGetStatusMessages(
  2547.     hPhone: THPhone;
  2548.     var lpdwPhoneStates, lpdwButtonModes, lpdwButtonStates: Longint): Longint;
  2549.  
  2550. function phoneGetVolume(
  2551.     hPhone: THPhone;
  2552.     dwHookSwitchDev: Longint;
  2553.     var lpdwVolume: Longint): Longint;
  2554.  
  2555. function phoneInitialize(
  2556.     var lphPhoneApp: THPhoneApp;
  2557.     hInstance: THandle;
  2558.     lpfnCallback: Pointer;
  2559.     lpszAppName: PChar;
  2560.     var lpdwNumDevs: Longint): Longint;
  2561.  
  2562. function phoneNegotiateAPIVersion(
  2563.     hPhoneApp: THPhoneApp;
  2564.     dwDeviceID, dwAPILowVersion, dwAPIHighVersion: Longint;
  2565.     var lpdwAPIVersion: Longint;
  2566.     var lpExtensionID: TPHoneExtensionID): Longint;
  2567.  
  2568. function phoneNegotiateExtVersion(
  2569.     hPhoneApp: THPhoneApp;
  2570.     dwDeviceID, dwAPIVersion, dwExtLowVersion, dwExtHighVersion: Longint;
  2571.     var lpdwExtVersion: Longint): Longint;
  2572.  
  2573. function phoneOpen(
  2574.     hPhoneApp: THPhoneApp;
  2575.     dwDeviceID: Longint;
  2576.     var lphPhone: THPhone;
  2577.     dwAPIVersion, dwExtVersion, dwCallbackInstance, dwPrivilege: Longint): Longint;
  2578.  
  2579. function phoneSetButtonInfo(
  2580.     hPhone: THPhone;
  2581.     dwButtonLampID: Longint;
  2582.     var lpButtonInfo: TPhoneButtonInfo): Longint;
  2583.  
  2584. function phoneSetData(
  2585.     hPhone: THPhone;
  2586.     dwDataID: Longint;
  2587.     lpData: Pointer;
  2588.     dwSize: Longint): Longint;
  2589.  
  2590. function phoneSetDisplay(
  2591.     hPhone: THPhone;
  2592.     dwRow, dwColumn: Longint;
  2593.     lpsDisplay: PChar;
  2594.     dwSize: Longint): Longint;
  2595.  
  2596. function phoneSetGain(
  2597.     hPhone: THPhone;
  2598.     dwHookSwitchDev, dwGain: Longint): Longint;
  2599.  
  2600. function phoneSetHookSwitch(
  2601.     hPhone: THPhone;
  2602.     dwHookSwitchDevs, dwHookSwitchMode: Longint): Longint;
  2603.  
  2604. function phoneSetLamp(
  2605.     hPhone: THPhone;
  2606.     dwButtonLampID, dwLampMode: Longint): Longint;
  2607.  
  2608. function phoneSetRing(
  2609.     hPhone: THPhone;
  2610.     dwRingMode, dwVolume: Longint): Longint;
  2611.  
  2612. function phoneSetStatusMessages(
  2613.     hPhone: THPhone;
  2614.     dwPhoneStates, dwButtonModes, dwButtonStates: Longint): Longint;
  2615.  
  2616. function phoneSetVolume(
  2617.     hPhone: THPhone;
  2618.     dwHookSwitchDev, dwVolume: Longint): Longint;
  2619.  
  2620. function phoneShutdown(hPhoneApp: THPhoneApp): Longint;
  2621.  
  2622.  
  2623. function lineTranslateDialog(
  2624.     hLineApp: THLineApp;
  2625.     dwDeviceID, dwAPIVersion: Longint;
  2626.     hwndOwner: HWnd;
  2627.     lpszAddressIn: PChar): Longint;
  2628.  
  2629. function lineGetCountry(
  2630.     dwCountryID, dwAPIVersion: Longint;
  2631.     var lpLineCountryList: TLineCountryList): Longint;
  2632.  
  2633. function lineGetAppPriority(
  2634.     lpszAppFilename: PChar;
  2635.     dwMediaMode: Longint;
  2636.     var lpExtensionID: TLineExtensionID;
  2637.     dwRequestMode: Longint;
  2638.     var lpExtensionName: TVarString;
  2639.     var lpdwPriority: Longint): Longint;
  2640.  
  2641. function lineSetAppPriority(
  2642.     lpszAppFilename: PChar;
  2643.     dwMediaMode: Longint;
  2644.     var lpExtensionID: TLineExtensionID;
  2645.     dwRequestMode: Longint;
  2646.     lpszExtensionName: PChar;
  2647.     dwPriority: Longint): Longint;
  2648.  
  2649. function lineAddProvider(
  2650.     lpszProviderFilename: PChar;
  2651.     hwndOwner: THandle;
  2652.     var lpdwPermanentProviderID: Longint): Longint;
  2653.  
  2654. function lineConfigProvider(
  2655.     hwndOwner: THandle;
  2656.     dwPermanentProviderID: Longint): Longint;
  2657.  
  2658. function lineRemoveProvider(
  2659.     dwPermanentProviderID: Longint;
  2660.     hwndOwner: THandle): Longint;
  2661.  
  2662. function lineGetProviderList(
  2663.     dwAPIVersion: Longint;
  2664.     var lpProviderList: TLineProviderList): Longint;
  2665.  
  2666. {$ENDIF}
  2667.  
  2668. implementation
  2669.  
  2670. {$IFDEF WIN32}
  2671.  
  2672. function lineAccept                   ; external 'Tapi32.dll' index 1;
  2673. function lineAddProvider              ; external 'Tapi32.dll' index 2;
  2674. function lineAddToConference          ; external 'Tapi32.dll' index 3;
  2675. function lineAnswer                   ; external 'Tapi32.dll' index 4;
  2676. function lineBlindTransfer            ; external 'Tapi32.dll' index 5;
  2677. function lineClose                    ; external 'Tapi32.dll' index 6;
  2678. function lineCompleteCall             ; external 'Tapi32.dll' index 7;
  2679. function lineCompleteTransfer         ; external 'Tapi32.dll' index 8;
  2680. function lineConfigDialog             ; external 'Tapi32.dll' index 9;
  2681. function lineConfigDialogEdit         ; external 'Tapi32.dll' index 10;
  2682. function lineConfigProvider           ; external 'Tapi32.dll' index 11;
  2683. function lineDeallocateCall           ; external 'Tapi32.dll' index 12;
  2684. function lineDevSpecific              ; external 'Tapi32.dll' index 13;
  2685. function lineDevSpecificFeature       ; external 'Tapi32.dll' index 14;
  2686. function lineDial                     ; external 'Tapi32.dll' index 15;
  2687. function lineDrop                     ; external 'Tapi32.dll' index 16;
  2688. function lineForward                  ; external 'Tapi32.dll' index 17;
  2689. function lineGatherDigits             ; external 'Tapi32.dll' index 18;
  2690. function lineGenerateDigits           ; external 'Tapi32.dll' index 19;
  2691. function lineGenerateTone             ; external 'Tapi32.dll' index 20;
  2692. function lineGetAddressCaps           ; external 'Tapi32.dll' index 21;
  2693. function lineGetAddressID             ; external 'Tapi32.dll' index 22;
  2694. function lineGetAddressStatus         ; external 'Tapi32.dll' index 23;
  2695. function lineGetAppPriority           ; external 'Tapi32.dll' index 24;
  2696. function lineGetCallInfo              ; external 'Tapi32.dll' index 25;
  2697. function lineGetCallStatus            ; external 'Tapi32.dll' index 26;
  2698. function lineGetConfRelatedCalls      ; external 'Tapi32.dll' index 27;
  2699. function lineGetCountry               ; external 'Tapi32.dll' index 28;
  2700. function lineGetDevCaps               ; external 'Tapi32.dll' index 29;
  2701. function lineGetDevConfig             ; external 'Tapi32.dll' index 30;
  2702. function lineGetID                    ; external 'Tapi32.dll' index 31;
  2703. function lineGetIcon                  ; external 'Tapi32.dll' index 32;
  2704. function lineGetLineDevStatus         ; external 'Tapi32.dll' index 33;
  2705. function lineGetNewCalls              ; external 'Tapi32.dll' index 34;
  2706. function lineGetNumRings              ; external 'Tapi32.dll' index 35;
  2707. function lineGetProviderList          ; external 'Tapi32.dll' index 36;
  2708. function lineGetRequest               ; external 'Tapi32.dll' index 37;
  2709. function lineGetStatusMessages        ; external 'Tapi32.dll' index 38;
  2710. function lineGetTranslateCaps         ; external 'Tapi32.dll' index 39;
  2711. function lineHandoff                  ; external 'Tapi32.dll' index 40;
  2712. function lineHold                     ; external 'Tapi32.dll' index 41;
  2713. function lineInitialize               ; external 'Tapi32.dll' index 42;
  2714. function lineMakeCall                 ; external 'Tapi32.dll' index 43;
  2715. function lineMonitorDigits            ; external 'Tapi32.dll' index 44;
  2716. function lineMonitorMedia             ; external 'Tapi32.dll' index 45;
  2717. function lineMonitorTones             ; external 'Tapi32.dll' index 46;
  2718. function lineNegotiateAPIVersion      ; external 'Tapi32.dll' index 47;
  2719. function lineNegotiateExtVersion      ; external 'Tapi32.dll' index 48;
  2720. function lineOpen                     ; external 'Tapi32.dll' index 49;
  2721. function linePark                     ; external 'Tapi32.dll' index 50;
  2722. function linePickup                   ; external 'Tapi32.dll' index 51;
  2723. function linePrepareAddToConference   ; external 'Tapi32.dll' index 52;
  2724. function lineRedirect                 ; external 'Tapi32.dll' index 53;
  2725. function lineRegisterRequestRecipient ; external 'Tapi32.dll' index 54;
  2726. function lineReleaseUserUserInfo      ; external 'Tapi32.dll' index 55;
  2727. function lineRemoveFromConference     ; external 'Tapi32.dll' index 56;
  2728. function lineRemoveProvider           ; external 'Tapi32.dll' index 57;
  2729. function lineSecureCall               ; external 'Tapi32.dll' index 58;
  2730. function lineSendUserUserInfo         ; external 'Tapi32.dll' index 59;
  2731. function lineSetAppPriority           ; external 'Tapi32.dll' index 60;
  2732. function lineSetAppSpecific           ; external 'Tapi32.dll' index 61;
  2733. function lineSetCallParams            ; external 'Tapi32.dll' index 62;
  2734. function lineSetCallPrivilege         ; external 'Tapi32.dll' index 63;
  2735. function lineSetCurrentLocation       ; external 'Tapi32.dll' index 64;
  2736. function lineSetDevConfig             ; external 'Tapi32.dll' index 65;
  2737. function lineSetMediaControl          ; external 'Tapi32.dll' index 66;
  2738. function lineSetMediaMode             ; external 'Tapi32.dll' index 67;
  2739. function lineSetNumRings              ; external 'Tapi32.dll' index 68;
  2740. function lineSetStatusMessages        ; external 'Tapi32.dll' index 69;
  2741. function lineSetTerminal              ; external 'Tapi32.dll' index 70;
  2742. function lineSetTollList              ; external 'Tapi32.dll' index 71;
  2743. function lineSetupConference          ; external 'Tapi32.dll' index 72;
  2744. function lineSetupTransfer            ; external 'Tapi32.dll' index 73;
  2745. function lineShutdown                 ; external 'Tapi32.dll' index 74;
  2746. function lineSwapHold                 ; external 'Tapi32.dll' index 75;
  2747. function lineTranslateAddress         ; external 'Tapi32.dll' index 76;
  2748. function lineTranslateDialog          ; external 'Tapi32.dll' index 77;
  2749. function lineUncompleteCall           ; external 'Tapi32.dll' index 78;
  2750. function lineUnhold                   ; external 'Tapi32.dll' index 79;
  2751. function lineUnpark                   ; external 'Tapi32.dll' index 80;
  2752. function phoneClose                   ; external 'Tapi32.dll' index 81;
  2753. function phoneConfigDialog            ; external 'Tapi32.dll' index 82;
  2754. function phoneDevSpecific             ; external 'Tapi32.dll' index 83;
  2755. function phoneGetButtonInfo           ; external 'Tapi32.dll' index 84;
  2756. function phoneGetData                 ; external 'Tapi32.dll' index 85;
  2757. function phoneGetDevCaps              ; external 'Tapi32.dll' index 86;
  2758. function phoneGetDisplay              ; external 'Tapi32.dll' index 87;
  2759. function phoneGetGain                 ; external 'Tapi32.dll' index 88;
  2760. function phoneGetHookSwitch           ; external 'Tapi32.dll' index 89;
  2761. function phoneGetID                   ; external 'Tapi32.dll' index 90;
  2762. function phoneGetIcon                 ; external 'Tapi32.dll' index 91;
  2763. function phoneGetLamp                 ; external 'Tapi32.dll' index 92;
  2764. function phoneGetRing                 ; external 'Tapi32.dll' index 93;
  2765. function phoneGetStatus               ; external 'Tapi32.dll' index 94;
  2766. function phoneGetStatusMessages       ; external 'Tapi32.dll' index 95;
  2767. function phoneGetVolume               ; external 'Tapi32.dll' index 96;
  2768. function phoneInitialize              ; external 'Tapi32.dll' index 97;
  2769. function phoneNegotiateAPIVersion     ; external 'Tapi32.dll' index 98;
  2770. function phoneNegotiateExtVersion     ; external 'Tapi32.dll' index 99;
  2771. function phoneOpen                    ; external 'Tapi32.dll' index 100;
  2772. function phoneSetButtonInfo           ; external 'Tapi32.dll' index 101;
  2773. function phoneSetData                 ; external 'Tapi32.dll' index 102;
  2774. function phoneSetDisplay              ; external 'Tapi32.dll' index 103;
  2775. function phoneSetGain                 ; external 'Tapi32.dll' index 104;
  2776. function phoneSetHookSwitch           ; external 'Tapi32.dll' index 105;
  2777. function phoneSetLamp                 ; external 'Tapi32.dll' index 106;
  2778. function phoneSetRing                 ; external 'Tapi32.dll' index 107;
  2779. function phoneSetStatusMessages       ; external 'Tapi32.dll' index 108;
  2780. function phoneSetVolume               ; external 'Tapi32.dll' index 109;
  2781. function phoneShutdown                ; external 'Tapi32.dll' index 110;
  2782. function tapiGetLocationInfo          ; external 'Tapi32.dll' index 111;
  2783. function tapiRequestDrop              ; external 'Tapi32.dll' index 112;
  2784. function tapiRequestMakeCall          ; external 'Tapi32.dll' index 113;
  2785. function tapiRequestMediaCall         ; external 'Tapi32.dll' index 114;
  2786.  
  2787. {$ELSE}
  2788.  
  2789. function tapiRequestMakeCall; external 'TAPI' index 28;
  2790. function tapiRequestMediaCall; external 'TAPI' index 101;
  2791. function tapiRequestDrop; external 'TAPI' index 112;
  2792. function lineRegisterRequestRecipient; external 'TAPI' index 10;
  2793. function tapiGetLocationInfo; external 'TAPI' index 85;
  2794. function lineSetCurrentLocation; external 'TAPI' index 81;
  2795. function lineSetTollList; external 'TAPI' index 3;
  2796. function lineTranslateAddress; external 'TAPI' index 19;
  2797. function lineGetTranslateCaps; external 'TAPI' index 100;
  2798. function lineAccept; external 'TAPI' index 82;
  2799. function lineAddToConference; external 'TAPI' index 47;
  2800. function lineAnswer; external 'TAPI' index 103;
  2801. function lineBlindTransfer; external 'TAPI' index 25;
  2802. function lineClose; external 'TAPI' index 78;
  2803. function lineCompleteCall; external 'TAPI' index 76;
  2804. function lineCompleteTransfer; external 'TAPI' index 73;
  2805. function lineConfigDialog; external 'TAPI' index 12;
  2806. function lineConfigDialogEdit; external 'TAPI' index 135;
  2807. function lineDeallocateCall; external 'TAPI' index 111;
  2808. function lineDevSpecific; external 'TAPI' index 21;
  2809. function lineDevSpecificFeature; external 'TAPI' index 22;
  2810. function lineDial; external 'TAPI' index 29;
  2811. function lineDrop; external 'TAPI' index 23;
  2812. function lineForward; external 'TAPI' index 87;
  2813. function lineGatherDigits; external 'TAPI' index 52;
  2814. function lineGenerateDigits; external 'TAPI' index 105;
  2815. function lineGenerateTone; external 'TAPI' index 80;
  2816. function lineGetAddressCaps; external 'TAPI' index 71;
  2817. function lineGetAddressID; external 'TAPI' index 104;
  2818. function lineGetAddressStatus; external 'TAPI' index 60;
  2819. function lineGetCallInfo; external 'TAPI' index 97;
  2820. function lineGetCallStatus; external 'TAPI' index 94;
  2821. function lineGetConfRelatedCalls; external 'TAPI' index 72;
  2822. function lineGetDevCaps; external 'TAPI' index 116;
  2823. function lineGetDevConfig; external 'TAPI' index 79;
  2824. function lineGetNewCalls; external 'TAPI' index 34;
  2825. function lineGetIcon; external 'TAPI' index 53;
  2826. function lineGetID; external 'TAPI' index 40;
  2827. function lineGetLineDevStatus; external 'TAPI' index 49;
  2828. function lineGetNumRings; external 'TAPI' index 62;
  2829. function lineGetRequest; external 'TAPI' index 86;
  2830. function lineGetStatusMessages; external 'TAPI' index 45;
  2831. function lineHandoff; external 'TAPI' index 11;
  2832. function lineHold; external 'TAPI' index 6;
  2833. function lineInitialize; external 'TAPI' index 33;
  2834. function lineMakeCall; external 'TAPI' index 32;
  2835. function lineMonitorDigits; external 'TAPI' index 24;
  2836. function lineMonitorMedia; external 'TAPI' index 15;
  2837. function lineMonitorTones; external 'TAPI' index 31;
  2838. function lineNegotiateAPIVersion; external 'TAPI' index 64;
  2839. function lineNegotiateExtVersion; external 'TAPI' index 17;
  2840. function lineOpen; external 'TAPI' index 46;
  2841. function linePark; external 'TAPI' index 5;
  2842. function linePickup; external 'TAPI' index 102;
  2843. function linePrepareAddToConference; external 'TAPI' index 50;
  2844. function lineRedirect; external 'TAPI' index 38;
  2845. function lineRemoveFromConference; external 'TAPI' index 43;
  2846. function lineSecureCall; external 'TAPI' index 57;
  2847. function lineSendUserUserInfo; external 'TAPI' index 63;
  2848. function lineSetAppSpecific; external 'TAPI' index 88;
  2849. function lineSetCallParams; external 'TAPI' index 2;
  2850. function lineSetCallPrivilege; external 'TAPI' index 95;
  2851. function lineSetDevConfig; external 'TAPI' index 107;
  2852. function lineSetMediaControl; external 'TAPI' index 37;
  2853. function lineSetMediaMode; external 'TAPI' index 115;
  2854. function lineSetNumRings; external 'TAPI' index 61;
  2855. function lineSetStatusMessages; external 'TAPI' index 44;
  2856. function lineSetTerminal; external 'TAPI' index 108;
  2857. function lineSetupConference; external 'TAPI' index 48;
  2858. function lineSetupTransfer; external 'TAPI' index 65;
  2859. function lineShutdown; external 'TAPI' index 8;
  2860. function lineSwapHold; external 'TAPI' index 109;
  2861. function lineUncompleteCall; external 'TAPI' index 41;
  2862. function lineUnhold; external 'TAPI' index 113;
  2863. function lineUnpark; external 'TAPI' index 77;
  2864. function lineReleaseUserUserInfo; external 'TAPI' index 139;
  2865. function phoneClose; external 'TAPI' index 119;
  2866. function phoneConfigDialog; external 'TAPI' index 16;
  2867. function phoneDevSpecific; external 'TAPI' index 9;
  2868. function phoneGetButtonInfo; external 'TAPI' index 4;
  2869. function phoneGetData; external 'TAPI' index 93;
  2870. function phoneGetDevCaps; external 'TAPI' index 114;
  2871. function phoneGetDisplay; external 'TAPI' index 83;
  2872. function phoneGetGain; external 'TAPI' index 68;
  2873. function phoneGetHookSwitch; external 'TAPI' index 27;
  2874. function phoneGetIcon; external 'TAPI' index 74;
  2875. function phoneGetID; external 'TAPI' index 106;
  2876. function phoneGetLamp; external 'TAPI' index 117;
  2877. function phoneGetRing; external 'TAPI' index 70;
  2878. function phoneGetStatus; external 'TAPI' index 39;
  2879. function phoneGetStatusMessages; external 'TAPI' index 55;
  2880. function phoneGetVolume; external 'TAPI' index 59;
  2881. function phoneInitialize; external 'TAPI' index 35;
  2882. function phoneNegotiateAPIVersion; external 'TAPI' index 7;
  2883. function phoneNegotiateExtVersion; external 'TAPI' index 14;
  2884. function phoneOpen; external 'TAPI' index 89;
  2885. function phoneSetButtonInfo; external 'TAPI' index 42;
  2886. function phoneSetData; external 'TAPI' index 92;
  2887. function phoneSetDisplay; external 'TAPI' index 98;
  2888. function phoneSetGain; external 'TAPI' index 67;
  2889. function phoneSetHookSwitch; external 'TAPI' index 51;
  2890. function phoneSetLamp; external 'TAPI' index 118;
  2891. function phoneSetRing; external 'TAPI' index 69;
  2892. function phoneSetStatusMessages; external 'TAPI' index 56;
  2893. function phoneSetVolume; external 'TAPI' index 54;
  2894. function phoneShutdown; external 'TAPI' index 26;
  2895. function lineTranslateDialog; external 'TAPI' index 13;
  2896. function lineGetCountry; external 'TAPI' index 143;
  2897. function lineGetAppPriority; external 'TAPI' index 58;
  2898. function lineSetAppPriority; external 'TAPI' index 66;
  2899. function lineAddProvider; external 'TAPI' index 141;
  2900. function lineConfigProvider; external 'TAPI' index 75;
  2901. function lineRemoveProvider; external 'TAPI' index 142;
  2902. function lineGetProviderList; external 'TAPI' index 129;
  2903.  
  2904. {$ENDIF}
  2905.  
  2906. end.
  2907.  
  2908.